Preben Alsholm

13728 Reputation

22 Badges

20 years, 248 days

MaplePrimes Activity


These are replies submitted by Preben Alsholm

x[6](t) = 0 should be x[6](0) = 0 or rather x[6](0) = a, where a is not zero, since introdu[3] has a singularity at x[i](t) = 0 for all i = 1..6.

x[6](t) = 0 should be x[6](0) = 0 or rather x[6](0) = a, where a is not zero, since introdu[3] has a singularity at x[i](t) = 0 for all i = 1..6.

@hirnyk Assuming you want the default range, yes that is simpler. However, in Maple 15 the default range for the basic trigonometric functions is not -10..10, but -2*Pi..2*Pi. Thus plot(sin) produces the same plot as plot(sin,-2*Pi..2*Pi).

@hirnyk Assuming you want the default range, yes that is simpler. However, in Maple 15 the default range for the basic trigonometric functions is not -10..10, but -2*Pi..2*Pi. Thus plot(sin) produces the same plot as plot(sin,-2*Pi..2*Pi).

Remember that you took the imaginary part in the original question.

Remember that you took the imaginary part in the original question.

@goli In my example x(t) = tan(t) is the solution satisfying the initial condition x(0)=0 and having as its maximal interval of definition (-Pi/2, Pi/2) using the usual requirement that the solution has to be (at least) defined and continuous on the interval. If you give up only continuity then

x(t) = piecewise(t<Pi/2,tan(t),tan(t-Pi/4))

is a solution satisfying x(0) = 0 and defined on the open interval (-Pi/2, 3*Pi/4), but it is not continuous at t = Pi/2.

Instead of tan(t-Pi/4) you could have used tan(t-c) for infinitely many other values of c and still have a solution defined on an interval containing (-Pi/2,Pi/2) as a proper subset.

That is why I say that it doesn't make sense to continue the solution on the other side of the singularity. If you  give up the requirement that the solution be defined at all points of the interval then the situation is of course no better.

@goli In my example x(t) = tan(t) is the solution satisfying the initial condition x(0)=0 and having as its maximal interval of definition (-Pi/2, Pi/2) using the usual requirement that the solution has to be (at least) defined and continuous on the interval. If you give up only continuity then

x(t) = piecewise(t<Pi/2,tan(t),tan(t-Pi/4))

is a solution satisfying x(0) = 0 and defined on the open interval (-Pi/2, 3*Pi/4), but it is not continuous at t = Pi/2.

Instead of tan(t-Pi/4) you could have used tan(t-c) for infinitely many other values of c and still have a solution defined on an interval containing (-Pi/2,Pi/2) as a proper subset.

That is why I say that it doesn't make sense to continue the solution on the other side of the singularity. If you  give up the requirement that the solution be defined at all points of the interval then the situation is of course no better.

I just installed Maple 15 and checked that indeed the subs-problem in animate is corrected in Maple 15, meaning that the two occurrences of subs have been replaced with eval's. 

I just installed Maple 15 and checked that indeed the subs-problem in animate is corrected in Maple 15, meaning that the two occurrences of subs have been replaced with eval's. 

@Robert Israel I have often enough suggested that the couple of occurences of subs in the animate procedure be replaced by eval's. I never got any response. Is it harmful in any way?

What I do to remedy the situation is the following and illustrated with Erik's example:

restart;

`plots/animate`:=subs(subs=((x,y)->eval(y,x)),eval(`plots/animate`)):

with(plots);
f := proc(t) if 5 < t then sin(t) else 0 end if end proc;
ball := proc (x, y) plots[pointplot]([[x, y]], color = blue, symbol = solidcircle, symbolsize = 40) end proc;
animate(ball, [4, 'f'(t)], t = 0 .. 10, frames = 200);

@Robert Israel I have often enough suggested that the couple of occurences of subs in the animate procedure be replaced by eval's. I never got any response. Is it harmful in any way?

What I do to remedy the situation is the following and illustrated with Erik's example:

restart;

`plots/animate`:=subs(subs=((x,y)->eval(y,x)),eval(`plots/animate`)):

with(plots);
f := proc(t) if 5 < t then sin(t) else 0 end if end proc;
ball := proc (x, y) plots[pointplot]([[x, y]], color = blue, symbol = solidcircle, symbolsize = 40) end proc;
animate(ball, [4, 'f'(t)], t = 0 .. 10, frames = 200);

In Maple 14 the result doesn't simplify so easily. However, doing simplify(xxx, symbolic); on the real looking solution does give the same result as Maple 13 does with just simplify.

In Maple 14 the result doesn't simplify so easily. However, doing simplify(xxx, symbolic); on the real looking solution does give the same result as Maple 13 does with just simplify.

Use 'numframes', not 'frames'. See the help page for DEplot (not DEplot3d).

First 207 208 209 210 211 212 213 Last Page 209 of 230