Binomial expansion 
Author Message
 Binomial expansion

 I need some assistance in coding the binomial series;

(1+x)^n = 1+ nx + n(n-1)x^2/2! + n(n-1)(n-2)x^3/3! + ...

I've got the factorial part and the algorithm for a exponential series (e^x);

ExpSeries (X,N)
e to x =1.0
lastterm =1.0
for termno = 1 to n
 nexterm =lastterm*x/termno
 e to x =e to x + nexterm
 lasterm = nexterm
endfor

How do I extend this to binomial series?

Cheers

------------------------------------------------------
Mariusz KOVLER

Telephone: 61 + 9 + 309 1011
Curtin University of Technology
"How many screensavers does it take to distract a professor?"



Wed, 18 Jun 1902 08:00:00 GMT  
 
 [ 1 post ] 

 Relevant Pages 
 

 
Powered by phpBB® Forum Software