Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Conflicting definitions of angle type #606

Closed
doug-q opened this issue Sep 10, 2024 · 3 comments · Fixed by #607
Closed

Conflicting definitions of angle type #606

doug-q opened this issue Sep 10, 2024 · 3 comments · Fixed by #607

Comments

@doug-q
Copy link
Contributor

doug-q commented Sep 10, 2024

ANGLE_TYPE has a comment describing the type as a dyadic rational multiple of \pi.

Other comments describe it as a dyadic rational multiple of 2\pi.

In my opinion the 2\pi definition is better because it allows the invariant that the numerator is always less than the denominator

@cqc-alec
Copy link
Collaborator

The two definitions are equivalent, but are perhaps both missing the clarifying point that angles that are equivalent mod 2π are considered equal.

(This means that the numerator isn't uniquely determined by the angle, so the problem goes away. We can still define a "canonical" numerator/denominator though which I agree should be the multiplier of 2π.)

github-merge-queue bot pushed a commit that referenced this issue Sep 10, 2024
@doug-q
Copy link
Contributor Author

doug-q commented Sep 10, 2024

The two definitions are equivalent, but are perhaps both missing the clarifying point that angles that are equivalent mod 2π are considered equal.

(This means that the numerator isn't uniquely determined by the angle, so the problem goes away. We can still define a "canonical" numerator/denominator though which I agree should be the multiplier of 2π.)

I don't agree that they are the same.

If they are multiples of \pi then the value (2,4) (value = 2, denom = 4, log_denom = 2) is \pi/2.
If they are multiples of 2\pi then the value (2,4) (value = 2, denom = 4, log_denom = 2) is \pi

@cqc-alec
Copy link
Collaborator

Yeah I just meant they are semantically equivalent, because x is a dyadic rational multiple of 2π if and only if x is a dyadic rational multiple of π.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants