Timeline for Is there any particular reason to only include 3 out of the 6 trigonometry functions?
Current License: CC BY-SA 4.0
11 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Jul 6, 2023 at 19:42 | vote | accept | CPlus | ||
Jun 30, 2023 at 20:46 | comment | added | RubenVerg | @DavidZhang I guess I just live in the wrong corner of programming languages :) glad to see they're in c23 though | |
Jun 30, 2023 at 17:53 | comment | added | tell | atan2 is a nice one. While the OP says there are six, this answer shows there are many more. Indeed there are more still, such as haversine (useful in navigation) and versine. This page mentions several cofunctions and cofunction identities. | |
Jun 30, 2023 at 16:25 | comment | added | SK-logic |
@PabloH this is what -ffast-math and alike a for, telling the compiler that you don't really care if optimisations break accuracy.
|
|
Jun 30, 2023 at 16:21 | comment | added | Pablo H | @SK-logic Numerical people are not fond of execution (generated code) being different from what's written. | |
Jun 30, 2023 at 8:48 | comment | added | SK-logic | Or just have your compiler recognise the pattern and replace it with an optimised version. It'd be far more user friendly. | |
Jun 30, 2023 at 4:38 | comment | added | David Zhang |
I am surprised to see you say that you've never seen sinpi and friends! Off the top of my head, they are implemented in MATLAB, Julia, in vendor libraries from Intel and Apple, and as of 2023, even the C standard library.
|
|
Jun 30, 2023 at 1:09 | comment | added | Pseudonym | @mousetail Sadly, the IEEE-754 standard costs money. | |
Jun 29, 2023 at 18:38 | comment | added | mousetail 'he-him' | Do you have a link to the IEEE document that recommends these functions? | |
Jun 29, 2023 at 18:24 | comment | added | CPlus |
Just as a side note I really like the *Pi functions because a) They're more precise and b) I don't need to manually multiply by pi
|
|
Jun 29, 2023 at 18:23 | history | answered | RubenVerg | CC BY-SA 4.0 |