Skip to content

@technobuddha > library > Geometry > Angle

Function: angleReflection()

ts
function angleReflection(
   angle: number, 
   axis: number, 
   options: UnitOptions): number;

Defined in: angle-reflection.ts:20

Calculates the reflection of an angle across a specified axis.

Parameters

ParameterTypeDescription
anglenumberThe angle to reflect.
axisnumberThe axis across which to reflect the angle.
optionsUnitOptionssee UnitOptions

Returns

number

The reflected angle, in the specified units.

Example

typescript
angleReflection(0, Math.PI / 2); // π
angleReflection((3 * Math.PI) / 2, Math.PI); // π/2
angleReflection(60, 30, 'degrees'); // 0