About 50 results
Open links in new tab
  1. Sine function in C - Code Review Stack Exchange

    Also, specifically for calculating sin, cos, etc, you probably shouldn't be recalculating things like factorials each time the function is run. In Musl's implementation, they simply store the values …

  2. c++ - Sine function calculated via look-up table and linear ...

    Jul 14, 2021 · The sine values calculation is based on the look-up table containing the pre-computed values of the sine function covering the whole period \$\left<0, 2\pi\right>\$ with 256 …

  3. Fast approximate sin/cos function in Rust - Code Review Stack …

    Mar 22, 2023 · Over the past month or so, I’ve been trying to create an extremely fast, platform agnostic, auto-vectorizing sin/cos function for fun. I initially started with sleef-rs’s fast sin …

  4. constexpr Sin Function C++ 14 - Code Review Stack Exchange

    Jul 2, 2016 · I have written a constexpr sin function using c++14 and would like to know what I can do to improve it. I am trying to balance code clarity/maintainability with performance. My goal …

  5. C++ templates for sin, cos, tan taylor series

    Aug 6, 2017 · I used C++ metaprogramming to build taylor series for sin, cos, and tan (not really for tan). The whole thing is on my github. Please give any feedback related (but not limited) to …

  6. c - Implementation of the trigonometric functions for real time ...

    Apr 14, 2021 · From the execution time point of view it seems to me that the best approach for real time application is to use the look-up table based method of calculation with improvement …

  7. Basic Trigonometry written in python3 - Code Review Stack …

    Below is the code I wrote to perform basic Trigonometry without using the math module (except for 1 place) for the purpose of teaching myself basic trig and to improve my python. I have …

  8. Compute the derivative of a function - Code Review Stack Exchange

    Apr 14, 2020 · The derivative of any function f (x) at x0 can be estimated according to the following formula: Write a program that prints three columns of numbers: x, f (x) and the …

  9. c++ - Calculating sine and cosine - Code Review Stack Exchange

    Mar 26, 2022 · This really is how many many good sin() functions work, but beyond the scope of this post. Only fair argument reduction π is an irrational number. All finite double are rational. It …

  10. Generate sinusoid as Wave file - Code Review Stack Exchange

    Oct 15, 2018 · You could give it other Function-Objects to produce the function of any expression you can write in C++. Or you could give SinFunction different frequency and/or duration …