integral over a finite sum with unknown upper limit
Subject: integral over a finite sum with unknown upper limit
From: i_inbox at tn-home.de
Date: Fri, 30 Jun 2006 11:56:25 +0200
Hello,
I would like to integrate over a finite sum with not yet known upper
limit n. Either, I get a noun limit or a noun integral that cannot be
further evaluated.
As a preparation, I've already told maxima: declare(n,integer); assume(n>0);
What I need to do is:
(%i5) integrate( sum( q[k]*s^k, k, 1, n ), s, 1, 2 );
(%o5) ('LIMIT('SUM(q[k]*s^(k+1)/(k+1),k,1,n),s,2,MINUS))
-('LIMIT('SUM(q[k]*s^(k+1)/(k+1),k,1,n),s,1,PLUS))
(in the application the summands are more complicated terms).
(%i6) ev(%,nouns);
(%o6) ('LIMIT('SUM(q[k]*s^(k+1)/(k+1),k,1,n),s,2,MINUS))
-('LIMIT('SUM(q[k]*s^(k+1)/(k+1),k,1,n),s,1,PLUS))
Why are the limits not taken?
Now, another example which fits better the application I have in mind:
(%i7) u[k](s) := s^k;
(%o7) u[k](s):=s^k
(%i8) integrate( sum( q[k]*u[k](s), k, 1, n ), s, 0, 1);
(%o8) 'INTEGRATE('SUM(q[k]*u[k](s),k,1,n),s,0,1)
(%i9) ev(%, nouns);
(%o9) 'INTEGRATE('SUM(q[k]*u[k](s),k,1,n),s,0,1)
Here, even the integration is not carried out.
But, maxima is able to integrate the summands:
(%i10) integrate( q[k]*u[k](s), s, 0, 1 );
(%o10) q[k]/(k+1)
I would like to get
sum( q[k]/(k+1), k, 1, n )
out of the input
integrate( sum( q[k]*u[k](s), k, 1, n ), s, 0, 1).
What must i tell maxima to get this right?
Your help would be very welcome.
Regards,
Tobias