News for hackers. Stuff that matters.
Re:Cosine Implementation in C by dboreham on Friday March 31, 2023 @12:37AM (#35382634)
My first experience with "Use the source Luke" was wondering as a young lad how computers calculated trig functions. This led me to the Unix V7 math lib source code[1], and thence to a book by Hart & Cheney which by luck my university library had on the shelf. Good times.

[1] https://github.com/v7unix/v7unix/blob/master/v7/usr/src/libm...

Re:Cosine Implementation in C by abudabi123 on Friday March 31, 2023 @02:29AM (#35383425)
A like minded reader may want to have a look at the Go lang. math standard library source.

* https://pkg.go.dev/math

Re:Cosine Implementation in C by cnity on Friday March 31, 2023 @09:40AM (#35387013)
What are the functions P and Q defined here? https://cs.opensource.google/go/go/+/refs/tags/go1.20.2:src/...
Re:Cosine Implementation in C by hurrrrrrrr on Friday March 31, 2023 @11:24AM (#35388504)
Polynomials with the coefficients defined in the sin and cos arrays (and likely in the referenced literature).
Re:Cosine Implementation in C by chubot on Friday March 31, 2023 @12:33PM (#35389538)
Woah why do they have s390x assembly versions of everything?

https://cs.opensource.google/go/go/+/refs/tags/go1.20.2:src/...

That's for a mainframe?