Content deleted Content added
Matthiaspaul (talk | contribs) →See also: +link |
mNo edit summary |
||
Line 1:
{{
{{
The terms '''binary angular measurement''' ('''BAM''')<ref name="ship"/> and '''binary angular measurement system''' ('''BAMS''')<ref name="BAMS"/> refer to certain methodologies for representing and manipulating [[angle]]s using [[binary number|binary]] ([[number base|base]] 2) [[fixed-point arithmetic]]. The [[unit of measure|unit]] of angular measure used in those methods may be called '''binary radian''' ('''brad''') or '''binary degree'''.
Line 11:
In this system, an angle is represented by an ''n''-[[bit]] unsigned binary number in the sequence 0, ..., 2<sup>''n''</sup>−1 that is interpreted as an multiple of 1/2<sup>''n''</sup> of a full turn; that is, 360/2<sup>''n''</sup> degrees or 2π/2<sup>''n''</sup> radians. The number can also be interpreted as a fraction of a full turn between 0 (inclusive) and 1 (exclusive) represented in binary fixed-point format with a scaling factor of 1/2<sup>''n''</sup>. Multiplying that fraction by 360° or 2π gives the angle in [[degree (angle)|degree]]s in the range 0 to 360, or in [[radian]]s, in the range 0 to 2π, respectively.
For example, with ''n'' = 8, the binary integers (00000000)<sub>2</sub> (fraction 0.00),
The main advantage of this system is that the addition or subtraction of the integer numeric values with the ''n''-bit arithmetic used in most computers produces results that are consistent with the geometry of angles. Namely, the integer result of the operation is automatically reduced [[modular arithmetic|modulo]] 2<sup>''n''</sup>, matching the fact that angles that differ by an integer number of full turns are equivalent. Thus one does not need to explicitly test or handle the wrap-around, as one must do when using other representations (such as number of degrees or radians in floating-point).<ref name="harg2019"/>
Line 21:
==See also==
* [[Grade (angle)|Grade]], 1/400 of a full turn
* [[Binary scaling]]
* [[CORDIC]], algorithms for trigonometric functions
* [[Constructible polygon]], including all polygons with 2<sup>''n''</sup> sides
|