From help-request at octave dot org Fri Feb 4 08:15:15 2005 Subject: Re: differential and integral calculus From: To: "Andreas Volz" , Date: Fri, 4 Feb 2005 09:15:07 -0500 ----- Original Message ----- From: "Andreas Volz" To: Sent: Thursday, February 03, 2005 14:32 Subject: differential and integral calculus > I'm a octave newbie and try to work with differential and integral > calculus. I need some help to get a working example for this. Could you > help me? > > Here is a simple example: > > f(x)=x^3+-2x^2+5 > f'(x)=3x^2-4x > > and for example integrating f'(x) to see that f(x) results. > You may have seen other responses to your quetion stating that Octave is a numerical program, rather than a symbolic one. In your example above, even if you had a program that would integrate symbolically, you should be aware that evaluating an indefinite integral introduces an arbitrary constant. For example: The integral of 3x^2 - 4x is x^3 - 2x^2 + C , where C is the arbitrary constant. Octave has routines for evaluating a definite integral numerically. > > f(x)=(x^2-3x)*sin x > f'(x)=? > Athough Octave will not provide a symbolic answer for the above example, you can use the formula below to provide approximations for plotting the derivative: f'(x) = limit[as dx approaches zero]((f(x + dx) - f(x))/dx) Choose dx to whatever accuracy you desire. ------------------------------------------------------------- Octave is freely available under the terms of the GNU GPL. Octave's home on the web: http://www.octave.org How to fund new projects: http://www.octave.org/funding.html Subscription information: http://www.octave.org/archive.html -------------------------------------------------------------