0 Members and 1 Guest are viewing this topic.

Something you absolutely need to know : if you want to use trig, just build some LUTs (look-up tables, tables to hold constant values instead of recalculating them) and leave sin() and cos() alone. Do that at the really beginning of your code ::_{E}90D3→°SinLUT+2→°CosLUT:L_{1}→SinLUT+256→CosLUT // L_{1} or whatever free RAM area of at least 512 bytes:~1 // the negate sign, not the minus:For(256) // 256 possible angles, from 0 to 255:sin(+1→r_{1})→{r_{1}+SinLUT}:cos(r_{1})→{r_{1}+CosLUT}:r_{1}:End

:_{E}90D3->°SinLUT+2->°CosLUT // gives two names to two numbers:L_{1}->SinLUT+256->CosLUT

:_{E}90D3→°SinLUT+2→°CosLUT:L_{1}→SinLUT+256→CosLUT // L_{1} or whatever free RAM area of at least 512 bytes:~1 // the negate sign, not the minus:For(256) // 256 possible angles, from 0 to 255:sin(+1→r_{1})→{r_{1}+SinLUT}:cos(r_{1})→{r_{1}+CosLUT}:r_{1}:End

With this way of thinking, you can still directly use L_{1}.