[TI-M] Re: The numerical integral


[Prev][Index][Thread]

[TI-M] Re: The numerical integral



robvanwijk@gmx.net wrote:
>> This isn't hard, as there's actually a command to shade the area between 
>> two curves, Shade(. Syntax as taken from the manual:
>> Shade(lowerfunc,upperfunc[Xleft,Xright,pattern,patres])
>> Calculating the difference of the two integrals can be done pretty 
>> easily as well; you'd simply subtract the two commands 
>> fnInt(...)-fnInt(...).
>> 
>> A four line program could get the job done with those commands.
> 
> Just an idea: use fnInt(f(x)-g(x)). This way, the OS will only have to
> evaluate one integral, so it should be faster.

Thanks for the help both of you. This new knowledge resulted
in the following program:

(the high and low functions is stored in Y1 and Y2).

Input "Lborder a:",A:Input "Hborder b:",B
Shade(Y2,Y1,A,B
fnInt((Y1)-(Y2),X,A,B)->X
Text(57,0,"Area:",X

:) Any more ideas for improvement?

-- 
/jonas                                         email: jonas@cytech.nu
Studying computer networks.                    icq@laptop: 130879882




References: