Sunday, April 17, 2016

Area Under the Curve Using Parametric Curves: Casio Classpad fx-CP400 and HP Prime (CAS)

Area Under the Curve Using Parametric Curves:   Casio Classpad fx-CP400 and HP Prime (CAS)

The CAS (computer algebra system) function paramint calculates the area under the curve of a function defined as the parametric curve (x(t), y(t)).  The integral is  ∫ y(t) * x’(t) dt .


Casio Classpad fx-CP400:  paramint




It would the most efficient way is use the Define command on the home screen (like the screen shot above). 

Define paramint(xt,yt,t0,t1) = ∫ (yt * diff(xt,t) dt, t = t0 to t = t1)


HP Prime:  paramint  (CAS Program)




The program paramint is going to be defined as CAS function.  When first creating paramint, check the CAS box before pressing the soft key (OK).  Also pay attention to the letters being typed while using the ALPHA key.  In the program editor, letters are defaulted to uppercase while CAS variables are lowercase.  Finally, commands called from the Toolbox in Program editing mode will have a “CAS.” suffix.  Erase the suffices. 


#cas
paramint(xt,yt,t0,t1):=
BEGIN
LOCAL n;
n:=int(yt*diff(xt,t),t,t0,t1);

return n;
END;
#end

Examples

Example 1:  x(t) = 2t^3 + 1, y(t) = t^2, t0 = 0, t1 = 1
Result:  6/5

Example 2:  x(t) = sin t, y(t) = 3 cos t, t0 = 0, t1 = π
Result: 3/2*π ≈ 4.71238898039


This blog is property of Edward Shore, 2016

Spotlight: Akron Brass FireCalc Pocket Computer

Spotlight: Akron Brass FireCalc Pocket Computer Welcome to a special Monday Edition of Eddie’s Math and Calculator blog. Thi...