Saturday, May 9, 2015

Casio Prizm Color Programs: Arc Length, Area Between Curves

Casio Prizm Color Programs

This blog will feature two programs:  arc length and area between curves.  After the calculation is complete, the results are displayed and plotted.

ARCPRZ:  Arc Length

Find the Arc Length of function Y1.  Once the arc length is calculated, the function is plotted, and the arc length is plotted in red. 

*  Functions are retrieved by pressing [VARS], [ F4 ] (GRAPH), [ F1 ] ( Y ). 

* To get Xdot, press [ VARS ], [ F1 ] (V-WIN), [ F1 ] ( X ), [ F4 ] for Xdot.

*  Color commands are found by pressing [SHIFT] [ 5 ] (FORMAT) and selecting Color commands.

*  The derivative function (d/dx) is not allowed as part of the integrand in the integral function ( dx) on Casio calculators. (At least for the fx-5800p, fx-9750g series, fx-9860g series, and the Prizm.  I am not sure about the Classpads).  Therefore, the Simpson’s Rule is used instead.  I use 100 divisions.

*  G SelOn and G SelOff I got from the CATALOG.  ([SHIFT], [ 4 ]).  I am not sure what menus where these two commands are located.

*  DrawGraph is found by pressing [SHIFT] [ VARS ] (PRGM), [ F6 ] (next page), [ F2 ] (DISPLAY), [ F2 ] (Graph)


Menu "USE Y1?","YES",1,"NO",2
Lbl 2
"Y1 (NO QUOTES)"? → Y1
Lbl 1
"LOW"? → A
"HIGH"? → B
For A→I To B Step S
√ (1+d/dx(Y1,I)^2)→U
I=A Or I=B T+U → T
If K≠0 And K≠100
2U+T → T
Frac (K/2)≠0 =>2U+T → T
K+1 → K
S/3*T → T
G SelOff
G SelOn 1
For A → I To B Step Xdot
Red PlotOn I, Y1(I)
Black Text 165,1,"ARC="
Black Text 165,65,T


Y1 = cos(X)*e^X from X = 1 to 2.   Arc Length = 4.7031139029…

Y1 = -2X^2 + 4X + 1 rom X = -2 to 2.   Arc Length = 20.7833…

AREABTWN:  Area Between Curves

This calculates the area between two curves, Y1 and Y2.  This program works best if you can set the graph screen to where the curves intersect at only two points.  The program first searches for two intersections, one from the left side of the graph screen (Xmin) and one from the right (Xmax).  After the area is calculated, both curves are graphed and the area between curves are shaded.  Function and Radian modes are used.


*  F-Line is found by pressing [SHIFT] [ F4 ] (Sketch), [ F6 ] (next page)

*  Since there is no shade function on the Prizm, a work around is needed.  Thankfully, there are FMin and FMax (function minimum and function maximum) functions that would make the picture look nice possible.

* ViewWindow seems to only affect the graph shown in Program mode when used as a command in program made.

* The program assumes that Function mode is set.

* In this listing, anything followed by double slashes (//) is a comment.  Do not type these lines into the program. 


Menu “USE Y1, Y2?”, “YES”, 1, “NO”, 2
Lbl 2
Y1 (NO QUOTES)”? → Y1
Y2 (NO QUOTES)”? → Y2
Lbl 1

// finding the end points

Solve(Y1-Y2, Xmin) → A
Sovle(Y1-Y2, Xmax) → B
If A > B
A → C: B → A: C → B: IfEnd
If A = B
Stop: IfEnd

// calculation

∫ (Y1-Y2, A, B) → I
Abs I → I

// start graphing routine

G SelOff
G SelOn 1
G SelOn 2

// setting the window

FMin(Y1, A, B) → List 25
FMin(Y2, A, B) → List 26
List 25[2] → U
List 26[2] → V
Min({U,V}) → E
FMax(Y1, A, B) → List 25
FMax(Y2, A, B) → List 26
List 25[2] → U
List 26[2] → V
Max({U,V}) → F
ViewWindow A-1,B+1,1,E-1,F+1,1

// now draw the graph


// shading routine

For A → K To B Step Xdot
Green F-Line K, Y1(K),K,Y2(K)


The Standard Window is used.  Xmin = -10, Xmax = 10, Ymin = -10, Ymax = 10

Y1 = -2X^2 + 4X + 1, Y2 = X^2.   Area = 2.734721…

Y1 = 1.2X + .63, Y2 = -X^2 + 5X + 1.   Area = 10.58676675…

A nice feature of the Prizm is that you transfer program files and screen captures from the calculator to the computer by just using the standard mini USB cable. 


This blog is property of Edward Shore, 2015.

No comments:

Post a Comment

HP Prime and TI-84 Plus: Basic Wheatstone Full Bridge Circuit

HP Prime and TI-84 Plus:  Basic Wheatstone Full Bridge Circuit The program WHEATSTONE (HP Prime) and WHTSTONE (TI-84 Plus CE) deals wi...