Carl Love

Carl Love

28035 Reputation

25 Badges

12 years, 318 days
Himself
Wayland, Massachusetts, United States
My name was formerly Carl Devore.

MaplePrimes Activity


These are replies submitted by Carl Love

@tomleslie The last valid value used for the independent variable and the corresponding values of the dependent variables can be retrieved by sol('last'), where sol is the solution procedure returned by dsolve. This may be more convenient than sol([lastexception][3]).

If you can't save a worksheet (from File => Save menu) to upload, can you send us a screenshot showing a command that works, its output, a command that doesn't work, its lack of output, then another that works and its output?

 

Just curiosity here: What's the purpose of the second column of your Matrix points, the one with the 10s and 30s? It seems to play no role in this.

Do not make followups by erasing your original Question and replacing it with the followup!! Put back your original Question. You've been on MaplePrimes for 9 years; one would think that you'd know better than to do something so uncouth.

@jan.droesler I'd be happy to continue to help you if you post your followup question here. If you post a followup as a new Question, it'll get deleted.

@tomleslie Oh, it's unquestionably a bug. I'm sorry that I didn't make that clear.

It looks like D has been extended in Maple 2019 to work on list-valued functions. So, for earlier Maple, change my tangent line definition from D(r)(a)*~(t-a)+~r(a) to

eval(diff(r(t),t), t=a)*~(t-a)+~r(a)

 

@Kitonum What part of it would you expect not to work? Here it is in use:

restart:
r:= t-> [t, t^2, t^3]:  (a,b):= (1,2):
 plots:-display(
    plots:-spacecurve~(
       [r(t), r(t), D(r)(a)*~(t-a)+~r(a)], t=~ [a..b, 2*a-b..a, 2*a-b..b], 
       color=~ [red, red, blue], linestyle=~ [1,2,1]
    ),
    thickness= 4, projection= 2/3, labels= [':-x',':-y',':-z'],
    tickmarks= [4$3], orientation= [76, 84, -23] 
);

@Carl Love I've corrected the Answer above. In the previous version, while I was formatting the session transcript in the MaplePrimes editor, a few lines were transcribed out of order, making the logical flow of my expository comments difficult to follow. If you read that Answer, then please reread the above. This time, I just uploaded my worksheet rather than trying to neatly format it into color-coded plaintext.

@Maximity Sorry, I forgot something: You need to include evalf, like this:

for i from 0 to evalf(Pi) by evalf(Pi/1000) do

But, this many points (21,021 = 1001 i x 21 j) is very slow to process. Here's an alternative that works from the plot.

Create a plot3d from the pdsolve(..., numeric) solution and save it to a variable:

P:= HS:-plot3d(u(x,t), t= 0..2, x= 0..Pi, grid= [50,50]);

The grid option specifies the number of evaluation points in the t dimension by the number in the x dimension.

Then use this procedure, which finds the maximum difference between this plot and the equivalent plot of the analytic solution.

PlotCompare:= proc(
    P1::specfunc(PLOT3D),
    Ana::procedure
)
local 
    G:= indets(P1, specfunc(GRID))[],
    P1data:= op(3,G),
    P2:= plot3d(Ana, op(1..2, G), grid= [upperbound(P1data)]),
    P2data:= op(3, indets(P2, specfunc(GRID))[])
;
    print(plots:-display(<P1 | P2>));
    max(abs~(P1data-P2data))
end proc
:
PlotCompare(P, Ana);

      0.00135289691747364


 

 

@Maximity You can simply use

for i from 0 to Pi by Pi/1000 do

It's usual in Maple to initilize Max to -infinity. This makes the code clearer to read, but there's no error (in this case) with your initiization to -2. Then if the final result is -infinity, you'll know that nothing was actually compared.

If your loop runs too slowly, I have some ways to speed it up.

Someone on here who very likely knows the answer to that is @Edgardo Cheb-Terrab @ecterrab. So, I just tagged him so that he'll see this.

@Scot Gould Just to be clear, I was referring to an Android / iOS version of Maple Player, not Maple itself.

Regarding the Maple Cloud: Until you brought it up, I was unaware that users could use the content interactively through a web browser. I've tried browsing it, but the file system is just too disorganized and the search features virtually non-existent (same two problem with MaplePrimes, btw).

I edited your Question to remove duplication, which probably wasn't your fault or intention anyway. All of the relevant details have been retained.

@Scot Gould I wonder if Maplesoft is working on a version of Maple Player for Android and related OSs. If so, then you could distribute your worksheets through a more-robust cloud-based file-sharing system like Google Documents.

An amazingly large subset of Maple can be had on one's phone in a calculator form with the free app Maple Companion. To a limited extent, one can download content to it simply by taking a photo of the content.

When I was teaching at a university (circa 1998-2004), I had a separate Yahoo Group for every class. This provided a file-sharing area for worksheets as well as a discussion forum.

First 221 222 223 224 225 226 227 Last Page 223 of 708