Beruflich Dokumente
Kultur Dokumente
Program Library
1
2
3
4
5
22
PROGRAM SHEET
Program for
No.
Description
Produces prime factors of arbitrary positive integers
For 1 < m < 1010
Prime numbers are produced from the lowest value first. END is displayed at the
end of the program.
(Overview)
m is divided by 2 and by all successive odd numbers (d = 3, 5, 7, 9, 11, 13, ....) to
check for divisibility.
Where d is a prime factor, mi = mi1/d is assumed, and division is repeated until
mi + 1 < d.
Example
[1]
119 = 7 17
[2]
440730 = 2 3 3 5 59 83
[3]
262701 = 3 3 17 17 101
412
Display
Display
No.
Line
File
name
1
2
3
4
5
6
7
8
9
10
11
Program
P
Lbl
Lbl
Lbl
Lbl
Lbl
Goto
Lbl
Lbl
Lbl
Lbl
Lbl
R
0
1
2
3
4
6
5
6
7
8
9
M
:
:
:
:
:
:
:
:
:
:
:
F
" M
2 ^
Frac (
A
B I
B
A
B
A
"
A C
" ?
A
A
+ 1
C
2
2
Goto
+ 2 B
B B
^ A B
^
E N D "
A : Goto
A :
) = 0
C :
8 : Frac
2 :
A = 1 Goto 9 :
Goto 1 : 3 B
(
: Goto 4 :
A = 0 Goto 7
A : Goto 3 :
: Goto 5
^ Goto 0
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
Memory Contents
27
A
B
C
D
E
F
G
mi
d
mi +1
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
413
PROGRAM SHEET
Program for
No.
Description
Euclidean general division is used to determine the greatest common measure for two
interers a and b.
For |a|, |b| < 109, positive values are taken as < 1010
(Overview)
n0 = max (|a|, |b|)
n1 = min (|a|, |b|)
nk2 nk1
nk = nk2
nk1
k = 2, 3....
If nk = 0, then the greatest common measure (c) will be nk1.
Example
[1]
When a = 238
b = 374
c = 34
[2]
[3]
a = 23345
b = 9135
a = 522952
b = 3208137866
c = 1015
c = 998
414
Display
Display
No.
Line
File
name
1
2
3
4
5
6
7
8
Program
C
Lbl
Abs
B
A
Lbl
C
B
Lbl
M N
F A C T
1 : " A " ? A
A A : Abs B B
< A Goto 2 :
C : B A : C
2 : () ( lnt ( A
= 0 Goto 3 :
A : C B : Goto
3 : B ^ Goto 1
"
"
? B
B
B )
:
:
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
Memory Contents
27
A
B
C
D
E
F
G
a, n0
b, n1
nk
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
415
PROGRAM SHEET
Program for
No.
t-Test Value
Description
The mean (sample mean) and sample standard deviation can be used to obtain a t-test
value.
t = (x m)
x
n1
Example
x
xn1
n
m
: mean of x data
: sample standard deviation of x data
: number of data items
: hypothetical population standard deviation (normally
represented by , but m is used here because of variable
name limitations)
To determine whether the population standard deviation for sample data 55, 54, 51,
55, 53, 53, 54, 52, is 53.
Perform a t-test with a level of significance of 5%.
Display
Display
The above operation produces a t-test value of t(53) = 0.7533708035. According to the t-distribution
table in the next page, a level of significance of 5% and a degree of freedom of 7 (n 1 = 8 1 = 7)
produce a two-sided t-test value of approximately 2.365. Since the calculated t-test value is lower
than the table value, the hypothesis that population mean m equals 53 is accepted.
416
No.
Line
File
name
1
2
3
4
5
6
Memory Contents
Program
T
{
5
l-Var
Lbl
(
"
Goto
5
4
List
0
x
T
0
T
5
,
1
:
E
,
5
,
"
M
"
A
B
C
D
E
F
G
S T
5 4 , 5
2 } List
1 _
M " ?
) ( xn1
: T ^
H
I
J
K
L
M
N
1 , 5
1 _
M _
O
P
Q
R
S
T
U
T _
V
W
X
Y
Z
t
t-distribution table
The values in the top row of the table show the probability (two-sided
probability) that the absolute value of t is greater than the table values
for a given degree of freedom.
P (Probability)
Degree
of Freedom
M :aM
T :aT
0.2
0.1
0.05
0.01
1
2
3
4
5
3.078
1.886
1.638
1.533
1.476
6.314
2.920
2.353
2.132
2.015
12.706
4.303
3.182
2.776
2.571
63.657
9.925
5.841
4.604
4.032
6
7
8
9
10
1.440
1.415
1.397
1.383
1.372
1.943
1.895
1.860
1.833
1.812
2.447
2.365
2.306
2.262
2.228
3.707
3.499
3.355
3.250
3.169
15
20
25
30
35
1.341
1.325
1.316
1.310
1.306
1.753
1.725
1.708
1.697
1.690
2.131
2.086
2.060
2.042
2.030
2.947
2.845
2.787
2.750
2.724
40
45
50
60
80
1.303
1.301
1.299
1.296
1.292
1.684
1.679
1.676
1.671
1.664
2.021
2.014
2.009
2.000
1.990
2.704
2.690
2.678
2.660
2.639
120
240
1.289
1.285
1.282
1.658
1.651
1.645
1.980
1.970
1.960
2.617
2.596
2.576
417
PROGRAM SHEET
Program for
No.
Description
Formula for circle:
x2 + y2 = r2
Y
A
(x',y')
r
0
With this program, slope m and intercept b (= y' mx') are obtained for lines drawn from
point A (x', y') and are tangent to a circle with a radius of r. The trace function is used to read
out the coordinates at the points of tangency, and factor zoom is used to enlarge the graph.
Example
To determine m and b for the following values:
r =1
x' = 3
y' = 2
Notes
The point plotted for A cannot be moved. Even if it is moved on the graph, the calculation is
performed using the original value.
An error occurs when r = x'.
Be sure to always perform a trace operation whenever you select trace and the message
TRACE is on the display.
Memory Contents
418
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
Z
No.
Line
File
name
Program
11
T
Prog
"
R
Prog
"
X
"
Plot
R
(
Lbl
12
Graph Y=
13
22
"
"
Lbl
"
Y
N
1
Z
Lbl
(
23
Graph Y=
24
"
"
Lbl
"
Y
N
2
Z
Lbl
"
"
1
2
3
4
5
6
7
8
9
10
14
15
16
17
18
19
20
21
25
26
27
28
29
30
31
32
33
34
A N G
" W I
X x2 +
= " ?
" C I
( X ,
= " ?
Y = "
A , B
x2 ( A
P
6 _
M ( X
M = "
B = "
0 _
T R A
E S
O 0
S :
= 0
2 _
() A B
N ( X
M = "
B = "
5 _
T R A
E S
O 0
S :
= 0
1 _
T R A
Factor N
:
E
N
Y
R
Y
?
^
x2
A
N
D
x2
R
C
)
A
T
O
=
_
L
_
_
B
+
B
B
)
x2
(
:
:
A ) +
M ^
B M
C
1
"
Z
Goto
:
:
E
_
:
=
2
W
R
" _
x2 _
"
R x2
x2
)
A
P _
x2 ) x1 M _
B ^
A ^
? _
? Z _
1 Goto 1 _
: Goto 0 _
P )
A ) +
N ^
B N
C
1
"
Z
Goto
E
_
:
=
3
? _
C
N
E
=
"
"
( R x2
B ^
x2
x1 N _
A ^
? Z _
1 Goto 1 _
: Goto 5 _
^
?
Factor
F _
419
No.
Line
35
36
37
38
39
40
41
42
43
Program
Prog "
S =
Graph Y= N
Goto 3
Lbl 9
Graph Y= M
Prog "
: Goto
Lbl 3
" E
C
2
(
_
_
(
W
6
_
N
R
Graph Y=
X
I N
_
C
M
A
L
(
)
"
I N
() 6
1 , 1
D
.
O W
3 , 6
File
name
Graph Y=
C
R
(
x2
File
name
View
Window
420
Graph Y=
I
()
R
(
E
X
+
A ) +
D O W
44
" : S
A )
B ^
=
+
B ^
" : Prog "
X x2
X
_
)
1 Goto 9 _
B _
"
() 3
Program for
Step
No.
4
Display
421
Program for
Step
10
422
No.
4
Display
Program for
Step
No.
4
Display
11
12
13
14
15
423
Program for
Step
16
17
18
424
No.
4
Display
PROGRAM SHEET
Program for
No.
Rotating a Figure
Description
Formula for coordinate transformation:
(x, y) (x', y')
A(x1, y1)
0
Example
To rotate by 45 the triangle defined by points A (2, 0.5), B (6, 0.5), and C (5, 1.5)
Notes
Use the cursor keys to move the pointer around the display.
To interrupt program execution, press A while the graphic screen is on the display.
The triangle cannot be drawn if the result of the coordinate transformation operation
exceeds View Window parameters.
Memory Contents
A
B
C
D
E
F
G
x1
y1
x2
y2
x3
y3
x'1
H
I
J
K
L
M
N
y'1
x'2
y'2
x'3
y'3
O
P
Q
R
S
T
U
V
W
X
Y
Z
425
No.
Line
Program
File
name
View
Window
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
426
.
"
X
"
Plot
X
"
X
"
Plot
X
"
X
"
Plot
X
Lbl
Line
"
A
A
Plot
C
C
Plot
E
E
Plot
Plot
Cls
O
()
4
(
1
Y
A
(
2
Y
C
(
3
Y
E
1
:
A
cos
sin
G
cos
sin
I
cos
sin
K
G
:
T
0
,
X
=
1
,
A
X
=
2
,
C
X
=
3
,
E
_
Plot
N
Q
Q
,
Q
Q
,
Q
Q
,
,
Plot
A T E
. 4 , 1 2 . 2
1 : Deg _
1 , Y 1 ) _
" ? A _
= " ? B _
B ^
: Y B _
2 , Y 2 ) _
" ? C _
= " ? D _
D ^
: Y D _
3 , Y 3 ) _
" ? E _
= " ? F _
F ^
: Y F _
A , B : Line
G L E : Deg
B sin Q
+ B cos Q
H _
D sin Q
+ D cos Q
J : Line _
F sin Q
+ F cos Q
L : Line _
H : Line ^
C , D : Plot
: Plot C , D
" ? Q _
G _
H _
() 0
: Line ^
I _
J _
K _
L _
: Goto 1
Program for
Step
Rotating a Figure
Key Operation
No.
5
Display
427
Program for
Step
Rotating a Figure
Key Operation
10
No.
5
Display