Mac Dude

1576 Reputation

17 Badges

14 years, 123 days

MaplePrimes Activity


These are replies submitted by Mac Dude

@Melykin Actually, TNBFrame() does allow you to control at least some aspets of the plot. Here are the options I am using to display a certain TNB frame (directly from a sheet of mine):

Student:-VectorCalculus:-TNBFrame(\
...
output=animation,range=0..214,frames=50,axes=boxed,\
                                   binormaloptions=[thickness=1,color=red],\
                                   tangentoptions=[thickness=1,color=black],
                                   normaloptions=[thickness=1,color=green]);

There are likely other options that work, too. In general, many options to plot and plot3d will work by being handed down to the lower-level routines.

Not arguing with your approach at all; just letting it be known that Maple can produce useful TNB frame plots & animations with relative ease.

M.D.

Melykin, you may also want to look at Student:-VectorCalculus:-TNBFrame() with the output=animation option. It creates in essence the same animated plot you show here. It is described in the help facility.

Mac Dude.

I have one called MAPLE An Introduction and Reference by Michael Kofler (Addison Wesley). Like spradlig's mention, it is much more than a rehash of the Manual and shows the limits and quirks of the system. Quite useful, up to a point.

The problem with all these is that they were written for Maple V. While the claim is made, at least by Rimrock, that Maple hasn't changed much under the hood, this is only partially true. vector and matrix have been superceded, modules and records are new and there are a host of new packages.

I would rather strongly recommend reading Maplesoft's documentation, esp. the User Manual and the Programming Guide (free to d/l). At least then you start with the more modern constructs. The older books then help you deal with the quirks and idiosyncrasies of Maple.

Mac Dude.

@Alejandro Jakubi I agree with all you are saying, except you are not mentioning the alternative, which is to bail out to "that other software." I am neither advocating that, nor do I have any clue whether Mma is any better in this regard as I am not hanging out on it's websites and have not used it for may years. But I do perceive loss of users for any reason, valid or not, as a risk for Maple and, as they say, the grass usually looks greener on the other side. Maplesoft is doing the right thing by asking users for their opinion; they are not being helped by us not pointing out where they can improve.

It is Maplesofts job to listen. I know from many posts here that people point out issues. I actually just checked upon my favorite graphics plot (the bug in plots:-display with log plots plotting linear when gridlines are on): and it is still not fixed. And this one I did SCR and even had  Maplesoft employee verify as a bug. Why should I SCR anything if something that basic does not get attention 2 versions after it was reported (I SCR'd Maple 15 for it)?

Yours very frustrated,

Mac Dude

 

@Jimmy The statistical indicator for goodness of fit is Chi^2/n, which is the sum of the squared residuals i.e. the sum of the squared differences between the data points and the fitted function evaluated at these points, divided by the degree of freedom. For practical purposes, the deg of freedom is the no. of data points minus the no. of free parameters being fitted. The division by n prevents the mere addition of parameters to seemingly give a better fit when the additional parameters are statistically insignificant (more parameters almost always reduce Chi^2, but not necessarily Chi^2/n).

Standard error or deviation are associated with the fitted parameters; they are related to Chi^2/n but not in a simple way and also strongly dependent on the form of your function, no. of free parameters etc.

M.D.

I used Mma many years (V2.2) and then had a long hiatus where my work did not require me of leave time to use CAS languages. Then a couple of years ago I found a need and decided to take advantage of the site license our lab has. I should also mention that I use Maple in  scientific context, mostly to simulate systems, do theoretical calculations, and analyse data. Education is not my main field although I am working on a course I will be giving next year; that course I am building with and around Maple.

Here are, without much prose, my reasons and thoughts:

Trivial reasons:
Availability as a site license at our lab, and licensing in general. Once installed & activated, I have it on a machine, no muss, no fuss, no license servers etc.
Relatively long support of PowerMacs. I have been and am still running some PPC Macs. Maple 15 runs fine on these. May become an issue again when Maple 18 comes out when support for Snow Leo is supposed to end. I hope it does not. I won't be able to switch to 10.7 anytime soon (obviously on Intel Macs).

Maple-capabilities related reasons:
I find modules and records to be an incredibly powerful feature set, allowing me to do "OOP lite" but complete enough to take very much advantage of.  Case in point: I recently needed to work out the magnetic field of rectangular Helmholtz coils. Building a Coils module with a "constructor" that creates a Coil record, a field-evaluation function and a couple of functions to rotate and translate a Coil instance I was able to, in about a couple of days, build a system that lets me model all sorts of weird coils, in fact leading to design optimizations I wouldn't have attempted otherwise. Unbeatable! I am also working on a package to do particle optics, where I use records to represent optical elements and overload some of the LinearAlgebra operations to string them together to build beam lines.

The close connection of Maple to Matlab is a plus in our lab, where Matlab is in widespread use.

I personally find the Maple language to be easier to learn and memorize than others, although I know that a number of people will disagree on that. Constructs like seq() and friends allow for a terse, functional programming style. I do not know whether other CAS have similar features, though.

I find the Physics: package intriguing and am working with it.

What could make me leave Maple for "that other system" (and this is a corallary question you need to ask):
Too many rough edges for my taste. Weirdnesses and outright bugs persist. E.g. plots:-display fails on logplots when gridlines are on (15 and I believe 17 as well). E.g. loading Threads: and using it gets the Maple kernel into a weird state with a hang upon restart (regression; was ok in 15, broken in 17). Others I forget but they are there.

Many commands are not "orthogonal", meaning they work only on certain data constructs (like on lists but not Vectors etc.) forcing unnecessary convert statements. I know Maple 17 is better in that regard than 15 and I appreciate that.

My biggest wish:
Fix those bugs! Maple is way too nice and powerful a package to let it not look polished. I would want many more updates between major versions, fixing things as the reports come in. There is no excuse to not do that. Avoid regressions at any cost.

(Remark here: I know this may be perceived as too general a statement. But the reality is that I am not paid to debug Maple but to produce results. So I am finding it difficult to make time to collect and catalog and SCR all the issues I am running across. In many cases one can find a work-around but I do find that need rather annoying. I am also rather keenly aware that some "bugs" are really the idiosyncrasies of a CAS and not really bugs. It is not a trivial situation. But I do maintain that, as I am getting deeper into it, Maple seems rougher than necessary or acceptable.)

Mac Dude

 

@acer You are right. Now that I reread your answer, I see your qualifications and advice loud & clear.

M.D.

 

@acer You are right. Now that I reread your answer, I see your qualifications and advice loud & clear.

M.D.

 

@acer: While your suggestions about warnlevel are certainly correct in a technical sense; I do wonder whether we really want to advocate turning warnings off. They can often indicate coding errors etc. and hint where one is going off-trail. Even in the case of the OP, an unexpected warning can hint at a typo that will go undetecte at warnlevel=1 or 0.

So, Gaia, please do not do that, for your own sake. Is is easy enough in Maple to write code free from warnings.

Just my $0.04,

M.D.

@acer: While your suggestions about warnlevel are certainly correct in a technical sense; I do wonder whether we really want to advocate turning warnings off. They can often indicate coding errors etc. and hint where one is going off-trail. Even in the case of the OP, an unexpected warning can hint at a typo that will go undetecte at warnlevel=1 or 0.

So, Gaia, please do not do that, for your own sake. Is is easy enough in Maple to write code free from warnings.

Just my $0.04,

M.D.

@ecterrab 

What I really want to do is to transform nuclear reaction cross sections from various systems (centre-of-mass, rest system of a moving particle etc.) to the lab system. I can of course do this just programming the respective formulae, but I like to use extant facilities (like the Physics package) so I can extend my calculations if I want to. 

So I think the Physics SpaceTimeVector should be the framework I need and the metric should be Minkowski by default. I haven't actually worked with it yet so I won't know for sure before I tried. Ideally, relations like the norm^2 of a 4-momentum being the rest energy come out naturally in the package. I'll find out.

Thanks,

M. D.

@ecterrab 

Starting to dig a little (actually for a beam-diagnostics project I am considering) I was looking for 4-Vectors and 4-momenta in the Physics package, but cannot find them.

Obviously I can cobble something together myself, but if it exists I'd rather use Physics for this. 

If 4-Vectors don't exist in Physics yet; wouldn't these seem like a worthwhile addition??

Mac Dude

Axel,

While I agree in general with you that a CAS should not try to become a desktop-publishing system, some of us publish papers using results or plots from Maple. Even though the rules are relaxed quite a bit nowadays, publications still need to have proper plots with correct labels and annotations. Sometimes a plot done in Maple is only doable in another program with a lot of extra work. So plots with custom tickmarks, proper typesetting in labels, what-have-you, are an important feature worth having and worth maintaining properly. I'd even argue that Maple is not leading in this dept.

Just my $0.02.

Mac Dude

 

Axel,

While I agree in general with you that a CAS should not try to become a desktop-publishing system, some of us publish papers using results or plots from Maple. Even though the rules are relaxed quite a bit nowadays, publications still need to have proper plots with correct labels and annotations. Sometimes a plot done in Maple is only doable in another program with a lot of extra work. So plots with custom tickmarks, proper typesetting in labels, what-have-you, are an important feature worth having and worth maintaining properly. I'd even argue that Maple is not leading in this dept.

Just my $0.02.

Mac Dude

 

After my reply to Alejandro Jabubi I looked at this a little more and realized that, in fact, pulling in the data form the CODATA file was quite easy since the Maple names to a large extent follow the same convention so the translation and matching up is fairly trivial. So I cobbled together a quick-and-dirty Maple procedure that pulls in the constants from the file and updates all those it finds a Maple equivalent for using ScientificConstants:-ModifyConstant.

So far so good; that part basically works. It becomes however quickly apparent that not all is well: the conversions between the units do not get updated and are now inconsistent with the values of the constants.

Example:

electron_mass is 9.10938291E-31 kg (correct 2010 value)

electron_mass*c^2 is 8.18710506545917E-14 J (Maple-calculated but in agreement with 2010 value except for some spurious digits)

convert(electron_mass*c^2,'units','MeV') is 0.510 998 683 613 828 MeV, which is wrong, the correct value is 0.510 998 928 (also in the data file)

So it appears the unit conversion does not get updated and does not use the ScientificConstant numbers (not per se surprising as these are separate packages). I poked around extensively but am not able to find where I can update the unit conversion constants. The data file has values for a number of these conversions so I can pull-in and modify these constants also.

Does anyone have a hint how to go about that?

M. D.

First 30 31 32 33 34 35 36 Last Page 32 of 42