rlopez

3020 Reputation

14 Badges

20 years, 236 days

Dr. Robert J. Lopez, Emeritus Professor of Mathematics at the Rose-Hulman Institute of Technology in Terre Haute, Indiana, USA, is an award winning educator in mathematics and is the author of several books including Advanced Engineering Mathematics (Addison-Wesley 2001). For over two decades, Dr. Lopez has also been a visionary figure in the introduction of Maplesoft technology into undergraduate education. Dr. Lopez earned his Ph.D. in mathematics from Purdue University, his MS from the University of Missouri - Rolla, and his BA from Marist College. He has held academic appointments at Rose-Hulman (1985-2003), Memorial University of Newfoundland (1973-1985), and the University of Nebraska - Lincoln (1970-1973). His publication and research history includes manuscripts and papers in a variety of pure and applied mathematics topics. He has received numerous awards for outstanding scholarship and teaching.

MaplePrimes Activity


These are answers submitted by rlopez

I thought this was an interesting enough question that I actually did a search, then decided that it would be faster to experiment. Here's my implementation of the trapezoid rule for nonuniform data.

X:=<1,4,5,9>:
Y:=<2,4,6,8>:
Z:=<seq(1+.1*k,k=0..80)>:
F:=CurveFitting:-ArrayInterpolation(X,Y,Z):
.1/2*(F[1]+F[80]+2*add(F[k],k=2..79));

The first two lines define some data. The third line gives the points at which interpolation is to be done by the ArrayInterpolation command. Note that this is part of the CurveFitting package. The return of the command is a vector of values at the interpolation points. The last line is an implementation of the trapezoid rule from first principles.

It would be nice if Maple had a built-in process for numerically integrating data. Maple is so "big" that this functionality could actually be there but I'm not aware of it! If it is, perhaps I'll learn something from a future Primes post.

RJL Maplesoft

Change D(x)*0 to D(x)(0)

RJL Maplesoft

The only place where Maple has implemented symbolic vector manipulations is in the Physics:-Vectors package.

RJL Maplesoft

Use the getdata command in the plottools package. Look at the help page for how this command works. It will give the data points used by Maple when constructing a graph.

RJL Maplesoft

In the final "display" command, change the set (given by {...}) to a list (given by [...]). A list is like a file-drawer. The things you put in it stay in the order in which they are placed. A set is like the desk drawer in which items are tossed randomly. In other words, sets do not preserve order, but lists do.

RJL Maplesoft

Typing the equation number directly into Maple does not work. Use Control+L to bring up the "Insert Label" dialog. In this pop-up, type just the equation number, not the parentheses around the number.

RJL Maplesoft

Bring up the Context Menu on the matrix. Then "Select Elements" and "Split into Columns".

RJL Maplesoft

The following three commands will do what you want.

with(Student:-MultivariateCalculus):
P:=Plane([A,B,C],<u,v,w>);
Distance([a,b,c],P);

In fact, these calculations can be implemented syntax-free via the Context Menu, once the Student MultivariateCalculus package has been loaded. See http://www.maplesoft.com/teachingconcepts/detail.aspx?cid=141 for a recorded example of how to do this.

RJL Maplesoft

By design, the ShowSolution command can be applied only to the evaluation of integrals, derivatives, and limits.

If the laplace transform is written as an integral, the ShowSolution command can display the steps of the integration. However, if the command is applied to the laplace command, no steps will be displayed because the ShowSolution command was never intended for such a case.

RJL Maplesoft

The Student MultivariateCalculus package has the ChangeOfVariables command that applies to inert multiple integrals. A general Cartesian iterated double integral is

q:=Int(F(x,y),[y=g(x)..f(f),x=a..b])

An application of the ChangeOfVariables command:

ChangeOfVariables(q,[cartesian[x,y],polar[r,t]])

The return is an iterated integral in which the integrand is expressed in polar coordinates, but the limits of integration are still the original Cartesian limits. Maple can only change the limits of integration in the simplest of cases.

The problem of changing the limits of integration is like that for changing the order of iteration in a multiple integral. The only way to do that is to draw the region of integration, and from the picture, figure out the limits of integration if the order of iteration is changed. It's the same problem with a change of coordinates. Draw the region of integration, and from the picture, figure out what those bounds would be in the new coordinate system.

In other words, changing the limits of integration when changing coordinates is a hard problem, one that has  not as yet been reduced to an algorithm.

RJL Maplesoft

No need for extended typesetting mode. In the label option of the plot command, use the following syntax: Typesetting:-Typeset(diff(phi(t),t))

I learned this several years ago from our graphics programmer, and wrote about it in a Tips&Techniques article for the Maple Reporter. The article is stored in the Maple Applications Center here: (http://www.maplesoft.com/applications/view.aspx?SID=141091)

RJL Maplesoft

The particular solution returned by DEtools:-particularsol actually has zero imaginary part if you apply simplify(evalc(Im... to it. The real part is, unfortunately, more complicated than it needs to be since it contains terms that are actually in the homogeneous solution.

The command dsolve(f,u[1](t),output=basis) will return a fundamental set (for the homogeneous solution) and a particular solution. This particular solution is much simpler than the one obtained by the particularsol command, and, after factoring, contains just one term from the homogeneous solution.

I know of no way to force Maple to return the "simplest" particular solution, either here, or in any of the cases I've encountered in my own work.

RJL Maplesoft

Click on the graph. Click on the "Drawing" button in the Plot Toolbar. There are now tools for drawing on the graph, and arrows can be so inserted. The disadvantage is that any re-execution of the graphing command will lose the drawn items. To counteract that difficulty, export the composite graph to some file format such as PNG, and then insert the graph into the worksheet as an image.

It's also possible to combine the graph of an arrow with the other graph. Draw the graph and assign it to a name such as p1. Graph the arrow and assign it to a name such as p2. Use the display command from the plots package to join p1 and p2 into a single image. Since this composite is done with Maple commands, re-execution re-creates the same composite.

Simplest way to draw the arrow with Maple commands is via the Student VectorCalculus package. Use the RootedVector command to create the arrow that has its tail at the root-point of your choice. Draw the arrow with the PlotVector command. (There are more primitive commands for creating and drawing arrows, but I find the tools in the VectorCalculus packages "simplest" to use.)

 

RJL Maplesoft

The task template at Tools/Tasks/Browse: Algebra/Rational Function - Graph and Asymptotes calls the Rational Function tutor, but in a format that embeds the results in the worksheet so that when the tutor is closed, the information generated by it does not disappear.

RJL Maplesoft

If this question was posed by a veritable new user of Maple, then probably such details as how one enters the differential equations, etc. are at the heart of the user's needs.

Suppose the user has changed the default setting of Maple so that he/she is in a worksheet using linear (1D math) inpput at the red prompts. Then the DEs would be entered as

eq1 := diff(x(t),t) = 2*x(t)-5*y(t)+t;

eq2 := diff(y(t),t) = 4*x(t)+9*y(t)+sin(t);

The solution of the IVP would be obtained with the command

Q := dsolve({eq1,eq2,x(0)=0,y(0)=0},{x(t),y(t)});

The solution for y(t) is most easily extracted via the syntax

Y:=eval(y(t),Q);

Evaluation at t=1 is then done via Y1 := eval(Y,t=1); Since this gives an exact value of some complexity, the next step would be conversion to a floating-point number via evalf(Y1).

Back when I was still teaching with Maple, only the command-version of the interface existed, so a lot of energy went into instructing students on a workflow and the concomitant syntax needed to accomplish the required calculations. From my 15-years experience using Maple with students in this environment, I think anyone who admits to being a new user deserves more help than simply being pointed to a Maple help page.

A much easier workflow can be implemented in a Document using typeset math input, but unfortunately, while this is easier to implement, it is harder to describe in writing. So, since there is a recorded demo of how to solve a linear system with syntax-free techniques already available, I'll not reproduce that solution here. In the Teaching Concepts section of the Maplesoft web site, one can find more than 150 examples implemented in the syntax-free paradigm Maplesoft has coined as Clickable Calculus.

RJL Maplesoft

First 15 16 17 18 19 20 21 Last Page 17 of 27