Math exams are coming up and the subject is intergral calculation.
So I thought I'd try to write a program to calculate the integrals of a function, and the possibility to calculate the area for a given interval and/or the volume of the body discribed by spinning it around the x-axis, also for a given interval.
How can I accomplish this?
Is there a built in function in C to calculate the integral of a function or do I need to write the procedure myself?
If I need to write the procedure myself, how do I do this?
Break the function into blocks and let it produce the integral for the given block by applying the methods used to calculate it? (a;n; func=ax^n integralfunc=(ax^(n+1))/(n+1) )
Should I make rules for special functions such as ln(), so the program can find the integral? Or should I make those functions into "normal" forms. (By the use of logarithms for ln() for example)
This post has been edited by Khaunshar: 07 June 2008 - 06:52 AM