Scot Gould

Scot Gould

732 Reputation

14 Badges

11 years, 150 days
Claremont McKenna, Pitzer, Scripps College
Professor of Physics
Upland, California, United States
Dr. Scot Gould is a professor of physics in the W.M. Keck Science Department of Claremont McKenna, Pitzer, and Scripps Colleges - members of The Claremont Colleges in California. He was involved in the early development of the atomic force microscope. His research has included numerous studies and experiments using scanning probe microscopes, particularly those involving natural fibers such as spider silk. More recently, he was involved in developing and sustaining AISS. This full-year multi-unit, non-traditional, interdisciplinary undergraduate science education course integrated topics from biology, chemistry, physics, mathematics, and computer science. His current interest is integrating computational topics into the physics curriculum. He teaches the use of Maple's computer algebraic and numerical systems to assist students in modeling and visualizing physical and biological systems. His Dirac-notation-based quantum mechanics course is taught solely through Maple.

MaplePrimes Activity


These are replies submitted by Scot Gould

@Carl Love 

I concur, there is added complexity and nuances when working with a symbolic language vs. a numeric-based language like C++.  Hence my point - be ready for a paradigm shift. Embrace it. The shift should provide computational and problem-solving gifts one probably has never imagined. (I nolonger see it is as a bug.) 

My only suggestion was that the eval, vs. rtable_eval or eval~ would be a intuitive function call for generating a fully evaluated rtable.  

(That said, even though I like “simplicity” of simplify(), I have followed the recommendation of @acer  by using eval~(). )

 

@opus64 

MaplePrimes.com is littered with questions related to the rules within Maple of when a variable is evaluated. I asked the same question less than a year ago; https://www.mapleprimes.com/questions/228316-Display-Vector-Components.  (Understanding the conditions for when an evaluation occurs required a significant paradigm shift.)

With regards to your question, my favorite answer has been: simplify, as in simplify(V). Who the heck remembers “rtable_eval”? While “eval~(V)” works, I feel “eval(V)” would be more intuitive. 

Aside: I would like to see all appropriate functions in Maple accept vector inputs. The function dsolve does, but solve does not.  (Being able to use vectors with dsolve is awesome - highly intuitive and readable.) 

If you plan to use Maple extensively, then I agree with the other contributors here that understanding the difference between an expression and a function is useful. An inexpensive textbook on using Maple functions is  "Getting Started With Maple" 4th edition, by Doug Meade, et.al. 

However, if you plan to use Maple only on occassion and wish to solve your math problems through icons and menu options (you did not indicate which version of Maple you are using), I suggest the Clickable Calculus video instructional series which are free (YouTube.) Go to https://www.maplesoft.com/products/maple/clickable_calculus/ 

 

I'm afraid I can't answer Maple 18, but I can tell you @Jean-Baptiste R , this is an option I would like them to provide / fix in 2020.1 

If one is in the text region, say the header, a right-click (alt-click) does bring up the menu to: 
* execute the selection, which it will not perform
* execute the entire worksheet: which it WILL perform

However, if one places the cursor with an execution group, the menu shows no options to execute the worksheet. (But one can hit the execute icon, "!" in the menu bar.) An option in the alt-click menu would be useful.

If one selects a section, or an execution group, there is no option in the alt-click menu to execute either the section or the worksheet. However, the menu bar "!" icon does work. Again, an option here would be useful. 

At a minumum, if one is in the text group, or header of a section, and the alt-click menu provides the option to execute the section, it should do it just like it does for the entire worksheet. (Or remove the option unless the section or set of execution groups are selected. 

Now that you have pointed out this ability to execute solely an section, I can see how it would be very useful - particularly in presentations. 

 

@Angela6884 I agree, the precision of the cursor on this particular plot is too broad for one to identify the value of f(x) the value at x = 2 with much accuracy.  Hence I suggest you plot a more narrow region.

In addition, if you are not aware, if you use the selection tool at the bottom of the drop-down menu (I have circled the button to show the menu) , then the cursor will follow the line. )  In the plot shown, at the location 2.00004, the value was 80.003 . That shoudl be close enough, yes?

@nm @Carl Love  I don't know next to nothing about the Gamma function, but I thought the integral would be a useful example in class. However, the first thing I noticed about the solution by Mathematica is that it is inversely proportional to beta. So what happens if beta = 0?  This is certainly a solvable integral if beta = 0. 

Next, I compared the integration of the integral for some sample values with the Mathematica solotion. Somewhere, there is a problem because unless beta = 1, the two don't appear to match. (And it is more than a constant.)  


 

restart

"Int0(alpha, beta) := ∫(e)^(alpha*t^(beta)) ⅆt  :"

"MMsol(alpha, beta) := -(t*(-alpha*t^(beta))^(-1/(beta))*GAMMA(1/(beta), -alpha*t^(beta)))/(beta)  :"

TestMMsol := proc (alpha, beta) print(Int0(alpha, beta), MMsol(alpha, beta), is(Int0(alpha, beta) = MMsol(alpha, beta))); plot([Int0(alpha, beta), MMsol(alpha, beta)], t = -1 .. 1, legend = ["Integration", "Solution"], linestyle = [solid, dot], thickness = [5, 3], color = ["Salmon", "DarkBlue"]) end proc

TestMMsol(1, 1)

exp(t), exp(t), true

 

 

TestMMsol(-2, 1)

-(1/2)*exp(-2*t), -(1/2)*exp(-2*t), true

 

 

TestMMsol(1, 2)

(1/2)*Pi^(1/2)*erfi(t), -(1/2)*t*Pi^(1/2)*erfc((-t^2)^(1/2))/(-t^2)^(1/2), false

 

Warning, unable to evaluate 1 of the 2 functions to numeric values in the region; complex values were detected

 

 

TestMMsol(1.0, 2.0)

.8862269255*erfi(t), -.5000000000*t*GAMMA(.5000000000, -1.0*t^2.0)/(-1.0*t^2.0)^.5000000000, false

 

Warning, unable to evaluate 1 of the 2 functions to numeric values in the region; see the plotting command's help page to ensure the calling sequence is correct

 

 

``

``


 

Download Mathematica_integral.mw

@krobe8 The "Export As=" directory is deep in a maple.ini file that is hidden in Windows. See my answer in the question that I possed 4 years ago. 

O happy day!

The following works for Windows users to ensure that the "Export As" (and the same may be true for "Save As" folder is the same folder in which the .mw file is location

* Go to the folder: c:\Users\<UserID>\Appdata\Roaming\Maple\<version> It is hidden uner the <UserID>, so you will have to enter the directory name in yourself. 

* Edit the file maple.ini with a text editor (Notepad). 

* Search for "Export As="

* It is likely to include a folder name. Delete the folder name so the line say "Export As="

* Make sure that no copies of Maple are running, else you will overwrite your work.

* Save the maple.ini file. 

* Restart Maple and test. 

For more info, see: https://www.maplesoft.com/support/help/Maple/view.aspx?path=worksheet%2freference%2finitialization

 

@krobe8 The File->Save As  command still chooses the same directory, but the all import File->Export As, now choose a directory I was working in the previous day, regardless of the current directory.  The Carl Love suggestion was added to the maple.ini file, (and the maplesys.ini), but that didn't work.

So, in short, what fiddling did you do to fix this problem?  (It is true, I just started working with some files that were created until Maple 2018. 

@amandaandi  I have worked with hundreds of new users, but this is a new one. My only suggestion is that you uninstall and then reinstall.  Or try to find another computer to install it on.

Sorry. I wish I had a better answer. (And nearly all problems I've seen with the installation process have been with Macs.)

Also, how did you activate it? Where did you obtain the activation code? This info might help folks answer your question. 

@acer Why you are at it, and to make this procedure even more useful, how does one modify "G" to print with an optional background color? 

@acer The simple procedures works perfectly - just as I had hoped. Saves me lots of time - much appreciated 

I did find one example of this type of question being asked in 2011, but it was for a command line output.  

Hopefully, the search system of MaplePrimes will point to this thread when the question is asked again. 

@janhardo 

If I understand what your goal, it is to generate output showing “prime” notation, or hopefully a “dot” notation, instead of the differential form.   I suspect that objective is independent of how one enters a statement into Maple. Hence using 1D or 2D Input is irrelevent.  I misunderstood you. I thought you were asking about the input becaust that is what Maple provides.  

Your interest in generating primes or dots in the output is different than mine. Mine is to use 2D Input because 2D Input looks like textbook math, thus it lowers the activation barrier for new users to adopt Maple.   Also, 2D Input is far more readable and understandable. Thus, 2D Input can play the role of 2D Output, simultaneously.

But your question about the dot notation did cause me to spend a little time with it. In the worksheet below, I do use it on vectors to which I obtain a highly readable document for anyone. However, there appear to be some unexpected outcomes. Possibly bugs.  They will be sent to technical support.

A couple separate points. While  I cannot speak for the mathematical world, the physics world, the “primed” notation is nearly always related to performing derivatives with respect to a position, x, and the “dot” notation is nearly always related to performing a derivative with respect to time, t.  Neither notation is viewed to be especially meant for vector calculus. Regardless, I do agree with you, using the notation with vectors does produce equations which appear to be less cluttered.

 

Note: In my opinion, the MaplePrimes document interpreter does not do justice to how nice this document reads. 
 

(Edited for a typo in the worksheet). 


 

In this example, Maple, because of its 2D Input, the worksheet is simply fantastic. It is readable to most anyone, including, and most importantly, to people who have never been exposed to Maple before.

restart

Write out a vector - and it looks like a vector!

 

"r(t) :=<x(t), y(t), z(t)>:    g := <0,-g, 0>:  "

 

Write out differential equation, using the "dot" notation. For most physicists, the dot notatation means differentiate with respect to time, t.   Note: no need to ask for a display of the output because the equation is self explanitory.

 

eq := m*(diff(`#mover(mi("r"),mo("&rarr;"))`(t), t, t)) = m*`#mover(mi("g"),mo("&rarr;"))`-c*(diff(`#mover(mi("r"),mo("&rarr;"))`(t), t))


Now set the initial conditions as one reads it in a paper:

initial_conditions := `#mover(mi("r"),mo("&rarr;"))`(t__0) = `<,>`(x__0, y__0, z__0), eval(diff(`#mover(mi("r"),mo("&rarr;"))`(t), t), t = t__0) = v__0*`<,>`(cos(theta), sin(theta), 0)


Solve the set of equations: eq and initial conditions for `#mover(mi("r"),mo("&rarr;"))`(t)

dsolve({eq, initial_conditions}, `#mover(mi("r"),mo("&rarr;"))`(t))

Vector[column](%id = 18446745964566591598) = Vector[column](%id = 18446745964566571118)

(1)

Absolutely beautiful.  It reads like math, and the derivation returns a vector using vector equations. No need to break up the vector equations into equations of individual component.

``


 

Download Example_2D_Input_of_Vectors_and_Dot_notation.mw

@Carl Love I completely agree that having a “set order” is incredibly useful, one that I have cherished since they modified it from the days when it appeared the order of the solutions was completely random. (Now I understand why that occurred. Much appreciated.)   

In addition, the current implementation of the “set order” is useful when working on physics problems where the mathematics can generate a slew of solutions. Nearly always, the first solution (or occasionally the first 2),  is  the only one that is physically viable. This is handy when discussing solutions in class. 

Hence, I can appreciate and benefit from the implementation of “set order” without spending the time to learn all its rules of it (given that at some point they may change).

First 11 12 13 14 15 16 17 Last Page 13 of 23