File: mysin.m

package info (click to toggle)
vc 1.4.5-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 4,552 kB
  • sloc: cpp: 19,220; ansic: 15,669; sh: 453; xml: 186; makefile: 30
file content (12 lines) | stat: -rw-r--r-- 460 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
function y = mysin (x)
  x2 = x.*x;
  y = 0;
  y = (y - to_double(0xACF0000000000 + 0, -41)) .* x2;
  y = (y + to_double(0x6124400000000 + 0, -33)) .* x2;
  y = (y - to_double(0xAE64567000000 + 0, -26)) .* x2;
  y = (y + to_double(0x71DE3A5540000 + 0, -19)) .* x2;
  y = (y - to_double(0xa01a01a01a000 + 0, -13)) .* x2;
  y = (y + to_double(0x1111111111110 + 0, -7)) .* x2;
  y = (y - to_double(0x5555555555555 + 0, -3)) .* x2;
  y = (y + 1) .* x;
endfunction