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

interface(rtablesize=n);

where n can be any integer (and even the word "infinity"). Alternatively, use the context menu to select the browse option. This launches an interactive dialog in which the entries of the Vector or Matrix appear.

RJL Maplesoft

Would the Student command SetColors help? With this command, a return to the older color scheme for graphs in the Student subpackages could be effected.

RJL Maplesoft

When the boundary condition is a linear combination of the heat flux and the temperature at an endpoint, I believe it is called a Robin boundary condition. (If the heat flux is prescribed, it is a Neumann condition. If the temperature is prescribed, it is a Dirichlet condition.)

At the left end, the condition could be expressed as D(T)(0)=a+b*T(0), for appropriate values of a and b.

RJL Maplesoft

I suspect that Maple is complaining about T(x) appearing in the boundary condition.

RJL Maplesoft

Student:-Calculus1:-Roots(sin(x)=x/8,x=-8..8,numeric);

Syntax for this command seems a bit simpler, and returns the real solutions sorted from smallest to largest.

RJL Maplesoft

Enter the ODE in 2D math mode, right-click on it and select "Solve DE Interactively." This brings up the ODE Analyzer Assistant, an interactive tool where the general solution, solution of an IVP, or simple BVP can be obtained, and the solutions graphed. For recorded demos showing how to implement these kinds of calculations in a syntax-free way, go to the Maplesoft website and look for recorded webinars.

RJL Maplesoft

Here's a guess at the advice you need.

The colon at the end of a for-loop suppresses all output of the loop. If, however, the loop is terminated with a semi-colon, then everything computed in the loop is echoed to the screen. To display selected calculations, terminate with a colon, and use print statements in the loop to display the selected items.

Nested loops display nothing, no matter what terminal punctuation is used. Here, print statements are needed to see intermediate results.

RJL Maplesoft

Once the problem is correctly typed into Maple, the two commands that are effective are allvalues and evalc. Thus,

q := inttrans[invlaplace](15/(s^3 + 6*s^2 + 15*s + 15), s, t);
q1 := allvalues(q); (A large expression results, but it does not contain sines or cosines.)

q2 := evalc(q1); (This will produce sines and cosines, but also in an exceeding complicated expression)

evalf(q2) returns

-4.529792160*exp(-1.838907323*t)*cos(1.754380960*t)+1.247818514*exp(-1.838907323*t)*sin(1.754380960*t)+4.529792154*exp(-2.322185354*t)

in which the sine and cosine functions are readily apparent.

 

Maple applies a partial fraction decomposition to the cubic, but this requires obtaining the roots, which are algebraic numbers, not nice integers. Hence the summation form of the inverse transform. The allvalues command takes care of the compacted inverse, and the evalc sorts the real and imaginary parts of the expression. Of course, the evalf floats all the algebraic numbers so that the final form shows sine and cosine multiplied by an exponential.

 

Typical textbook exercises don't get into these messy extensions of basic ideas, but that's what Maple is for, provided one knows how to extract the desired results from what Maple provides.

 

RJL Maplesoft

In plotting and in the plots and VectorCalculus packages, the names given to the variables in spherical coordinates are irrelevant. It's the position of the variables in the commands that use them that matters. For example, in the VectorCalculus packages, the order of the coordinates is "radial coord, angle down from the z-axis, angle around z-axis". It doesn't matter what names are given to the three coordinates - their interpretation is based on their positions in the triple of names.

To graph the unit sphere in spherical coordinates, the usage would be plot3d(1, u=0..2*Pi,v=0..Pi,coords=apherical). The first angle is the one around the z-axis; the second, down from the z-axis. The names of these angles are irrelevant - the first given is the one around; the second, down.

In the Physics package, the names do matter. The angles must be called theta and phi, with the physics convention being followed: theta is down from the z-axis, and phi is around the z-axis. The triple of names is (rho, theta, phi). Since the meaning of the angles is now connected to the name of the variable used, it's clear that the convention is the same as in the VectorCalculus packages, namely, that the middle coordinate is the one down from the z-axis.

It should be noted that math texts tend to call the angle around the z-axis "theta" and the angle down from the z-axis "phi", and that physics and engineering texts tend to reverse these two names. It should be noted further that math and science texts seem to be randomly split between the ordering of the variables in the triple of variable names. I have found texts that follow the math names for the angles, some using the order (rho, phi, theta) and some using the order (rho, theta, phi). Hence, it is essential when looking at any calculations in spherical coordinates to be sure of the definitions the author is using.

I might point out where and when I discovered how important it was to check definitions for spherical coordinates. It was at RHIT, in teaching Advanced Calculus to a mix of math, physics, and engineering students. Some of the physics students were using formulas from their physics texts, and of course, these results looked very different from my own math usage. That's when I began noting very carefully what different definitions were extant in texts, and how these meshed with what Maple was using. These distinctions were essential when I wrote my Advanced Engineering Mathematics text, a volume that is now available from the Maple website as an ebook.

RJL Maplesoft

Change the colon (:) after EQ2 to the assignment operator :=. For notational convenience, replace theta_double_dot with Y, say. Replace square brackets with round parentheses. (That's essential in Maple.) Apply solve({EQ1,EQ2,EQ3},{u,s,Y}), but get back a "solution" in terms of the RootOf structure. Not much help there.

eliminate({EQ1.EQ2.EQ3},{Y,s}) gives Y and s as functions of u, with u determined by a difficult transcendental equation in u. Not sure how much help that would be.

To work numerically, use fsolve instead of solve, but now all parameters other than the variables u, s, and Y must be numeric, not symbolic. Even then, you might have to tell fsolve where to look for solutions.

As you have probably already noticed, this appears to be a computationally difficult problem.

RJL Maplesoft

It appears to me that the function 40-x*arccosh(56/x) has a minumum of about 3 at x near 30. I don't see how  you get even one real solution of this equation.

RJL Maplesoft

It takes some doing in Maple to define a true vector-valued function of a vector argument. The input to the functions G1 and G2 are not vectors. Nor is the output a vector. A vector is defined with the Vector command or with angle brackets (use inequality symbols) as in <1,2,3>.

Round parentheses are used for function arguments, and will "disappear" when used in other places. For example, trying to define a point as (1,2) doesn't work because there is no data structure corresponding to the use of round parentheses.

Finally, to simplify the result of G1G2(a,b,c), use simplify([G1G2(a,b,c)]), where the square brackets define a list. The return from G1G2(a,b,c) is just an expression sequence, and many commands such as simplify do not accept the expression sequence.

RJL Maplesoft

The symbol "dx" when x is an independent variable, means any increment in x, large or small. If y=y(x), then the symbol dy, the differential of y, is defined (it is a definition!) to be y'(x)dx, that is, the derivative of y, times an increment (large or small) in its independent variable. Of course, as dx gets small, the differential dy becomes a better approximation to the true change in y, namely, y(x+dx)-y(x).

So I guess the real question here is whether the differentials you want to manipulate are increments in independent variables, or actually differentials of functions. In the latter case, replacing dy with diff(y(x),x)*dx might work. But as stated earlier, without a clearer idea of the details of your calculation, we can only speculate.

RJL Maplesoft

Maple does not have a differential "d" operator. The int/Int commands take as argument the integrand, and the variable of integration, say, x. Maple then writes the integral with a "dx" symbol, but the dx in that case is purely notational. It is not an operator that the user can access. The closest Maple comes to differentiation by operator is the d/dx operator in the Expression palette. I suspect this is of little help for a programmer who is probably writing code in linear (1D math) style of input.

Maple also has the D operator, but this is a differentiation operator, not a differential operator. Applied to a function, it represents the derivative of the function.

Given a more specific idea of what it is you are trying to do, it might be possible to accomplish the task using the existing Maple functionalities, but from the limited scope of the stated question, it's not clear what additional information is relevant.

RJL Maplesoft

If you want to solve for "a" in terms of x, y1 and y2, then do not make an assignment to x. The operator := is the assignment operator. The equation should probably be x=..., and if this needs a name, use a different letter, as in

q:=x=...

Apply the solve command to the equation whose name is q, and which has x on the left of the equal sign, etc.

Incidentally, what the command solve(x,a) actually did was to set the expression whose name was x equal to zero, and solve that for a. That's why x does not appear in the RootOf object that was returned.

Finally, the RootOf construction is a compressed way for expressing the root of an equation. Maple can use this to express roots that would otherwise be large and messy expressions, or it can use this to express roots that really can't be found in closed form. I believe that is the case here. I don't see any obvious way to solve the intended equation in closed form. What the RootOf construct is really saying is "If you can solve for the Maple-generated variable _Z, then you will have the desired root. Since it appears that there's no closed-form expression for _Z, the best that can be done is to look for a numeric solution. But that requires x, y1 and y2 all to be numeric.

RJL Maplesoft

First 21 22 23 24 25 26 27 Page 23 of 27