-
Notifications
You must be signed in to change notification settings - Fork 0
/
PEREL7.TXT
131 lines (131 loc) · 2.02 KB
/
PEREL7.TXT
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
LBL "PEREL7" ;ellipse perimeter calculus
;modified cycloid
;
;input
; a ENTER b ENTER XEQ PEREL7
; a and b half ellipse parameter
;
;output
; Perimeter
;
;R22-24 used
;R07-08 A and B
;
;
;first try
;shortened cycloid giving result of error < 0.0256273% with FOCAL
; https://en.wikipedia.org/wiki/Anomalous_magnetic_dipole_moment
; by use of constant 1.159652182 factor electron bohr magneton as Z
; exponent instead of 1 in X=r*t^Z -c*sin(t)
; https://de.wikipedia.org/wiki/Zykloide
;
;improvement 1
; 1.159652182 factor corrected after analysis with SCFPER1
; and definition of a new curve fitting. New error < 0.0017254%
; at R 0.9564309 (Perim = 4) and Theta 0.269498rad
;
;improvement 2
; tbd
;
;under CC BY SA creative commons 4.0 pascaldagornet at yahoo dot de
;
;change log
;2021 10 05 original
;2021 10 19 rework improvement 1
;
X>Y?
X<>Y
X=0?
GTO 04
STO 07 ;b in 07
X<>Y
STO 08 ;a in 08 and now is a bigger than b
RAD
2
SQRT
PI
/
CHS
0.5
+
STO 22 ;secure reuse param 1/2 - SQRT(2)/pi
0.000000001 ; search for t
0.999999999
"ZWFT"
ASTO 06 ; in case of use of SOL from MATH module
XEQ "SOLVE" ;solve from Advantage
PI
*
COS
CHS
1
+
RCL 22
*
CHS
1
+
1/X
RCL 07
X^2
RCL 08
X^2
+
SQRT
*
4
*
RTN
LBL "ZWFT" ;calulating the t for the atan(b/a) angle
STO 23 ;secure parameter t
PI
*
SIN
RCL 22
*
CHS
STO 24 ;temporary storage
RCL 23 ;t
-0.0797049
*
0.186975
+
RCL 23
1.15542
*
CHS
1.05411
X<>Y
Y^X
*
RCL 23
0.158842
Y^X
*
1.03111
+
RCL 23
X<>Y
Y^X
PI
*
4
/
ST+ 24
RCL 08
RCL 07
/
ATAN
ST+ 24
PI
2
/
ST- 24
RCL 24
RTN
LBL 04
X<>Y
4
*
RTN
END