acer

33188 Reputation

29 Badges

20 years, 209 days
Ontario, Canada

Social Networks and Content at Maplesoft.com

MaplePrimes Activity


These are replies submitted by acer

@dharr The OP has asked before about getting the prime notation in pretty-printing of expressions used in plots. (Others have asked it or similar questions too, eg here, and others)

The same underlying issue (that the setting/level is not being respected during the mark-up) affects titles, captions, textplots, labels, etc. Ie. anywhere that math can get marked up and displayed in a plot.

Your solution of InertForm:-Typeset (and another variant I've sometimes used of InertForm:-Display) has the benefits over Typesetting:-Typeset that:
1) it's a documented command
2) it doesn't have special-evaluation rules (and so directly handles this example in which the formula has been assigned to a name)

I'm going to submit a bug report against this somewhat long-standing issue.

@WD0HHU As was visible in the output shown in my Answer, I used Maple 2024.2.

I might have time to look at Maple 2025... later.

@WD0HHU Notice the Maple version in my posting. If your version is different then it's only helpful if you tell us what it is.

@Gabriel Barcellos It is not explicitly stated in the original Question that the problem deals with a physical situation. It may well be true, and there may hints to that effect, but it was not overt.

Thank you for the clarification.

There were a few places where the simplification process needed some extra hand-holding (...for my line, sometimes to prevent it from undoing/overdoing some step I wanted...).

But, yes, often calling simplify (possibly after evala/radnormal/evalc...) on the difference is a good way to start. It's much more robust to turn the difference into zero than it is to "simplify" both expression to the very same form (which might not be "canonical" or obvious as the common target).

In this example the assumptions of the parameters being real is also part of what Maple needs to make some of the intermediate conversions (even without extra hand-holding). Using the assuming facility is often very convenient for that.

@sand15 You wrote,

      replace T = AN/2 * BN/2 by (A*B)N/2

but those are not mathematically equivalent, and that substitution is not valid in general. For example, at the point,
    N=1, beta=7*I, eta1=1, eta2=-I+1, gamma1=1, gamma2=1

You could guarantee it by, say, taking A and B as positive. Now, both A and B consist of 1 added to some exp calls. And so one way to ensure that A,B are positive is to take the parameters as real, so that all the arguments to the exp calls are purely real. So considering the parameters being being real is sufficient.

Also, those steps and reductions -- as well as the picking terms out structurally with op -- could be done more mathematically (ie. non-structural programmatic steps, all steps done explicitly, from start to finish, etc).

@Andiguys 

You've been shown how to put the numeric values for the parameters in a caption, in an Answer to another Question of yours made today. For fun I'll give yet another way to generate that, in the attached worksheet below.

Note also that you could simply change the option name caption to title here, and move them to the top. I'm not sure whether that will export to .png file ok in your Maple 2022.

Note that there are already simple textplots (for pi[m]^DS, etc) in the above answer and plots. I'm not sure whether you want to keep those.

The attachment has a few variants, with/without those previous simple textplots, with/without the previous legend items, etc.

You could also mark the regions with textplots similar to your current legend items (or instead of the legend if you'd prefer). You can do that by putting additional textplots inside additional rectangles. I showed you how to do that kind of thing in an Answer to your Question of 21/01/2026.

Q1_3_ac_3.mw

All the items,


With the previous legend items and simple textplot region-labels,



ps. You can also pass option captionfont (or titlefont if using title) if you want it bold, etc.

pps. If those aren't the exact "labels" you had in mind for then it's because you haven't stated clearly what you wanted them to be.

Just an FYI, for those interested:

Some years ago I found out that the plotting substructure such as THICKNESS(0.1), with a positive float value less than 1, would cause the GUI to render a line thinner than it would for THICKNESS(0).

At that time pretty much no plotting command would do anything with a supplied option such as, say, thickness=0.1 except  to turn it into the suboptimal THICKNESS(0).

These days some commands (such as plot) will handle an option thickness=0.1 and construct the expected, matching substructure. But there are some commands which still may not, eg. DrawGraph. But the good news is that one can still supply thickness=0 and then substitute a replacement into the structure, as I did in my Answer below.

pl_thick_note.mw

@Mister_Matthew_abc If you can still access the email address linked to your older Mapleprimes account then you ought to be able to reset the password associated with it (sent as a link via email, from the login page, say)

The 5th bullet point of Description section the Help page ?procedure shows the syntax as being of the form,

   description descriptionSequence;

and the Parameters section of that Help-page explains descriptionSequence as a "sequence of strings describing the procedure".

A terminating semicolon is shown in the syntax. The word description is shown in lowercase. The fact that descriptionSequence can be a sequence of one or more strings is mentioned, and a string in Maple is documented by being wrapped in double-quotes.

Maple is a case-sensitive language. Sometimes case is used to distinguish functionality and purpose, eg. int versus Int. Alongside that, having other command names (such as Describe) be accepted case-insensitively would be a generally confusing.

The following example shows that, in both 2D and 1D input modes, the elements of the sequence may each be a string or a name.

restart

f := proc (x) description `first one`, "foo", s, "last one"; x^2 end proc

proc (x) description `first one`, "foo", s, "last one"; x^2 end proc

Describe(f)


# first one
# foo
# s
# last one
f( x )
 

Download description_01.mw

So it might be an improvement to document that a terminator is mandatory for each of the optional clauses.
nb.The following may not be valid syntax, despite being unambiguous,

proc(x) description "hey now" end proc;
Error, reserved word `end` unexpected

It might be an improvement to document that the elements of the description sequence may each be strings or names.

@WD0HHU I will repeat some of my points, to address your Reply. Wording is important to understanding the cause of problems.

Explore assemblies looks clunky in part because the Embedded Components and the GUI layout elements (eg. Table) are a bit clunky.

The Explore Library command constructs from those, and the GUI inserts and renders them.

That GUI rendering (alone) dictates the font of the tick marks on a Slider, and their font size, which are the aspects you mentioned. There are additional EC issues, like cross-platform appearance, Slider selection granularity, and (some) key aspects of the Table layout, and others.

@Kitonum Yes, that was one of the points I made in my previous Answer.

I'll move that paragraph from the end to the top of my Answer, in the hope it doesn't get missed.

Sorry, I missed that you also asked about possibly hiding the Slider's tickmark(value) labels(markers).

You can do that in the Explore call like so,

Explore(plot(sin(a*x),gridlines),
        parameters=[[a=-3.0..3.0,showlabels=false]]);

That hides them if you find them too large in font-size, but wouldn't help completely with extra white-space issue that you mentioned.

The syntax idea in the above code snippet is that when you use the longer-form for specifying the Explore parameters, ie,
    Explore(..., parameters=[ [...], [...] ] )
then you can add options specific to each Slider/ComboBox/other-controller within those sublists. See the programmatic Slider constructor Help-page.

You can also right-click on the Sliders in the (already embedded) exploration assembly, and change this Component Property via the popup menu.

Why did you start using this account instead of your old one?

A couple of interesting weaknesses,

restart;

kernelopts(version);

`Maple 2024.2, X86 64 LINUX, Oct 29 2024, Build ID 1872373`

ff := -I*((-1)^(1/9)+1)*(2*(-1)^(5/9)-2*(-1)^(4/9)+1)*1/(-1+(-1)^(1/9));

-I*((-1)^(1/9)+1)*(2*(-1)^(5/9)-2*(-1)^(4/9)+1)/(-1+(-1)^(1/9))

evala(ff);

2*(-1)^(5/6)-I

evala(%); # not idempotent

-3^(1/2)

radnormal(ff); # dusty trusty

-3^(1/2)

restart;

gg := (2*(-1)^(17/18)-(-1)^(11/18)+3^(1/2))/((-1)^(1/9)-1);

(2*(-1)^(17/18)-(-1)^(11/18)+3^(1/2))/((-1)^(1/9)-1)

simplify(gg); # unchanged

(2*(-1)^(17/18)-(-1)^(11/18)+3^(1/2))/((-1)^(1/9)-1)

evala(gg);

-3^(1/2)

Download simp_rad_0x.mw

I'll submit bug reports against those two.

@C_R You also mentioned that Relational Round palette in the recent Question I cited (and for which that palette also contained symbols  `≅`  and  `⊈` under discussion there).

I didn't take the opportunity to make that palette visible at that time, so missed it again.

Vote up.

3 4 5 6 7 8 9 Last Page 5 of 607