```
Starting find y=sin(x)
degrees = 0   sin= 0
degrees = 1   sin= 1.745240643728299E-002
degrees = 2   sin= 3.489949670249994E-002
degrees = 3   sin= 5.233595624294227E-002
degrees = 4   sin= 6.975647374412323E-002
degrees = 5   sin= 8.715574274765558E-002
degrees = 6   sin= .1045284632676504
degrees = 7   sin= .1218693434051439
end phase
now lets do the differences
these are the differences
0   0
1   1.745240643728299E-002
2  -5.316172066054115E-006
3  -5.314552708548387E-006
4   3.238221774060079E-009
5   1.617877765786035E-009
6  -1.479018296723922E-012
7  -4.928106533963472E-013
end of differences
output phase
deg= 0   0                                0 %
deg= 1   1.745240643728299E-002           0 %
deg= 2   3.489949670249994E-002           0 %
deg= 3   5.233595624294227E-002           0 %
deg= 4   6.975647374412323E-002           0 %
deg= 5   8.715574274765558E-002           0 %
deg= 6   .1045284632676504                0 %
deg= 7   .1218693434051439                0 %
deg= 8   .1391731009600598               -1.116819431163829E-012 %
deg= 9   .1564344650402142               -7.682555272252131E-012 %
deg= 10   .1736481776668701              -3.172784093519301E-011 %
deg= 11   .1908089953763488              -9.981644706980273E-011 %
deg= 12   .2079116908172055              -2.634695712374428E-010 %
deg= 13   .2249510543424764              -6.143583656829062E-010 %
deg= 14   .2419218955965042              -1.304738175067687E-009 %
deg= 15   .2588190450958489              -2.574923054224631E-009 %
deg= 16   .2756373558037917              -4.788738639197643E-009 %
deg= 17   .2923717046979395              -8.478516127811638E-009 %
deg= 18   .3090169943304361              -1.440129769071371E-008 %
deg= 19   .3255681543802874              -2.360793163437235E-008 %
deg= 20   .3420201431973094              -3.752688261243128E-008 %
deg= 21   .3583679493372042              -5.806486939547702E-008 %
deg= 22   .3746065930872721              -8.772653958720248E-008 %
deg= 23   .3907311279822668              -1.297557087879522E-007 %
deg= 24   .406736642309902               -1.88300417841488E-007 %
deg= 25   .4226182606055139              -2.686050015034725E-007 %
deg= 26   .4383711451353898              -3.772318369850072E-007 %
deg= 27   .4539904973682679              -5.223163054765945E-007 %
deg= 28   .469471559434517               -7.138581283008616E-007 %
deg= 29   .4848096155725017              -9.640530863930685E-007 %
deg= 30   .4999999935616417              -1.287668960348078E-006 %
deg= 31   .5150380661416715              -1.702470039979665E-006 %
deg= 32   .5299192524176082              -2.229694885982281E-006 %
deg= 33   .5446390192499343              -2.894592097033148E-006 %
deg= 34   .559192882629503               -3.727019632858856E-006 %
deg= 35   .5735764090366724              -4.762113147391215E-006 %
deg= 36   .5877852167841772              -6.041029565251767E-006 %
deg= 37   .6018149773432432              -7.611772388388278E-006 %
deg= 38   .6156614166524542              -9.530105566356719E-006 %
deg= 39   .6293203164088758              -1.186056371938256E-005 %
deg= 40   .6427875153409452              -1.467756638521996E-005 %
deg= 41   .6560589104626341              -1.80666452191319E-005 %
deg= 42   .6691304583083901              -2.212579285584689E-005 %
deg= 43   .6819981761483667              -2.69669439491917E-005 %
deg= 44   .694658143183446               -3.271759824707966E-005 %
deg= 45   .7071065017195638              -3.952259752984242E-005 %
cheers

************  and the program to generate the above is **********

print "hello, I am 0-sin"
print
print "regular diff equations
print "7th order, 1 degree per step
print
DIM stepval#(40)
DIM w#(40)
Pi# = 3.1415926535897
OPEN "0-sin.txt" for OUTPUT as #2

print #2, "Starting find y=sin(x)
for x# = 0 to 7
degrees# = x#
radians# = degrees#*Pi#/180
stepval#(x#)=  sin(radians#)
print "degrees =" degrees#, "sin=" stepval#(x#)
print #2, "degrees =" degrees#, "sin=" stepval#(x#)
next x#
print #2,"end phase

print #2,"now lets do the differences
for n% = 0 to  7
w#(n%) = stepval#(0)
' print #2, " ** n="n%; " w="w#(n%)
for i% = 0 to (7-n%)
'  print #2, "      n=";n%; " i=";i%, stepval#(i%+1);" - "stepval#(i%);
stepval#(i%) = stepval#(i%+1) - stepval#(i%)
' print #2, "=";stepval#(i%)
next i%
next n%

' these differences are now in w#()
print #2,"these are the differences
for n% = 0 to 7
print n% " " w#(n%)
print #2, n% " " w#(n%)
next n%
print #2,"end of differences

print #2, "output phase
for n# = 0 to 45
degrees# = n#
radians# = degrees#*Pi#/180
s# = sin(radians#)
if (s# <> 0) then
e# = ((w#(0)-s#)*100)/s#
else
e# = 0
end if
print     " deg=",degrees#;" "; w#(0),  e#;"%"
print #2, " deg=";degrees#;" "; w#(0),  e#;"%"
for i% = 0 to 7
'     print w#(i%);
'     print #2, w#(i%);
w#(i%) = w#(i%) + w#(i%+1)
next i%
'  print
'  print #2, " "
next n#
print "cheers"
print #2, "cheers"

```