Download Print this page

Casio fx9750GII Getting Started page 40

Graphic calculator
Hide thumbs Also See for fx9750GII:

Advertisement

PROGRAMMING
Example 3
'Factors of Numbers', is a
program that finds all factors of
any input number, checks whether
it is prime, and / or a perfect
number and counts the number
of factors.
A program that can stimulate a
project on 'Special Numbers', for
example.
The calculator executes about
550 calculations a minute.
checking some of those 2
primes!
Refer to the 'Programme Mode
Command List' for entering and
editing the program. (See index
for page reference)
Example 4
The 'Mendelbrot' is a well-known use of imaginary numbers, named after its discoverer, the US
mathematician Benoit Mendelbrot. The program draws part of the Mendelbrot Set.
'Zooming In' on a specific part of the Mendelbrot Set can be done by editing the Viewing Window in the
first 4 lines of the program.
The set is related to the complex function f(z)=z
around the boundaries and are very similar to each other, that is, they are smaller versions of the larger
ones The program requires a lot of calculations to be made, as the screen is set to 127x63x30. That is,
about ¼ million calculations in total.
Try the View Window at:
(a)
-1.5 < x < -1.1 and
-0.1 < y < 0.1
(b)
-0.8 < x < -0.4 and
0.5 < y < 0.7
Refer to the 'Programme Mode
Command List' for entering and
editing the program.
for page reference)
"FACTOR OF NUMBERS" 
Lbl 0
?→A
0→Z
0→K
0→N
Lbl 1
0→B
0→C
0→D
K+1→K
Int (A÷K)→B
Try
A÷K→C
-1
n
B-C→D
D=0⇒K
D=0⇒N+1→N
D=0⇒B+Z→Z
A=K⇒Goto 2
Goto 1
Lbl 2
"INPUT NUMBER"
+ c, with c being a constant. Many 'spikes' are evident
2
"MENDELBROT" 
-2→Xmin
0.5→Xmax
-1→Ymin
1→Ymax
(Ymax-Ymin)÷62→V
for example
(Xmax-Xmin)÷126→H
Xmin→X
Ymin→Y
While X<Xmax+H
While Y<Ymax+V
X+iY→Z
0→N
Z→C
While Abs Z<2 And N<30
(See index
Z
+C→Z
2
N+1→N
WhileEnd
A
"PERFECT NUMBER CHECK"
Z
""
N=2⇒Goto 3
Z=2xA⇒"THE INPUT NUMBER
IS A
PERFECT NUMBER"
""
"THERE ARE"
N
"FACTORS"
"ALL FACTORS ARE NOW
FOUND"
""
"PLEASE TRY AGAIN"
Goto 0
Lbl 3
"THE INPUT NUMBER IS A
PRIME NUMBER"
If N>29
Then Plot X, Y
IfEnd
Y+V→Y
WhileEnd
Ymin→Y
X+H→X
WhileEnd
Stop

Hide quick links:

Advertisement

loading