strawfields93

0 Reputation

One Badge

12 years, 279 days

MaplePrimes Activity


These are questions asked by strawfields93

My program is to compute the sequence of integrals of Jn = int(x^(2n)*sin(pi*x), x=0..1) for n=1...N to 10s.f where N=10.

This is my program but it keeps telling me it is missing an operator and I'm unsure why.

N:= 10:
In:= evalf(2/Pi):

for n from 0 by 1 to (N - 1) do

In:=evalf((1/(Pi^2))*(Pi-((2n+1)*(2n+2)*In))):

maple_In := evalf(Int((x^(2n))*sin(Pi*x), x = 0..1), 20):

printf( "%d %10.10f %10.10f %10.10f \n" , n + 1 , In , maple_In , abs( In - maple_In ...
Page 1 of 1