From a76977af62010a392c16010c367185e61e856ffe Mon Sep 17 00:00:00 2001 From: Dimitri Sokolyuk Date: Wed, 30 Oct 2019 20:04:56 +0100 Subject: mv to docs --- j1demo/firmware/sincos.fs | 36 ------------------------------------ 1 file changed, 36 deletions(-) delete mode 100644 j1demo/firmware/sincos.fs (limited to 'j1demo/firmware/sincos.fs') diff --git a/j1demo/firmware/sincos.fs b/j1demo/firmware/sincos.fs deleted file mode 100644 index 6ad1ea4..0000000 --- a/j1demo/firmware/sincos.fs +++ /dev/null @@ -1,36 +0,0 @@ -( Sine and cosine JCB 18:29 11/18/10) - -create sintab - -meta - -: mksin - 65 0 do - i s>d d>f 128e0 f/ pi f* fsin - 32767e0 f* f>d drop - t, - loop -; -mksin - -target - -: sin ( th -- v ) - dup d# 128 and >r - d# 127 and - dup d# 63 > if - invert d# 129 + \ 64->64, 65->63 - then - cells sintab + @ - r> if - negate - then -; - -: cos d# 64 + sin ; - -: sin* ( s th -- sinth * s ) - sin swap 2* m* nip ; - -: cos* ( s th -- costh * s ) - cos swap 2* m* nip ; -- cgit v1.2.3