Casio CFX-9970G

User Manual - Page 445

For CFX-9970G.

PDF File Manual, 474 pages, Download pdf file

Loading ...
Loading ...
Loading ...
428
PROGRAM SHEET
Program for
Greatest Common Measure
Description
Euclidean general division is used to determine the greatest common measure for two
interers a and b.
For |a|, |b| < 10
9
, positive values are taken as < 10
10
(Overview)
n0 = max (|a|, |b|)
n1 = min (|a|, |b|)
nk–2
nk = nk–2 ––– nk–1
nk–1
k = 2, 3....
If nk = 0, then the greatest common measure (c) will be nk–1.
Example [1] [2] [3]
When a = 238 a = 23345 a = 522952
b = 374 b = 9135 b = 3208137866
↓↓
c = 34 c = 1015 c = 998
Preparation and operation
Store the program written on the next page.
Execute the program as shown below.
Step Key operation Display Step Key operation Display
No.
2
Loading ...
Loading ...
Loading ...