acer

33171 Reputation

29 Badges

20 years, 194 days
Ontario, Canada

Social Networks and Content at Maplesoft.com

MaplePrimes Activity


These are answers submitted by acer

The discont=true option can work if the fallback value for the piecewise is undefined instead of [] the empty list.

Using Maple 2026.0,

plot_piecewise_march_25_2026_ac.mw

 

Maple 2025.2 and Maple 2026.0 return true (and 0) for these, without any conversion.

You're not doing something wrong; it's a bug, that has since been improved.

restart

kernelopts(version)

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

is(convert(exp(u)/(1+exp(u))^2 = 1/(4*cosh((1/2)*u)^2), exp))

true

simplify(convert(exp(u)/(1+exp(u))^2-1/(4*cosh((1/2)*u)^2), exp))

0

NULL

Download test1_ac.mw

In Maple 2024.2 you could also convert to trigh (ie. change the lhs rather than the rhs).

I've submitted a report on this in the past. But it couldn't hurt (and might help) if you'd like to submit your own bug report against it.

The font used (and possibly also that Component's spacing) is not the same on all of the Windows/Linux/Mac OS's. On my Maple 2024.2 for Linux I can fit 16 numerals into a TextArea with "Visible Character Width" set to 10.

On Linux (at least) the font used for TextArea components is not a fixed-width font, so it matters which characters are used. It's unclear what is meant by "Visible Character Width" in such a context. See lowercase "i" vs uppercase "W".

[edit]
Best solution: fixed-width font that has same size and appearance on all three OS (and if that can't be done in Java, then... oof).
Worst solution: same fonts as now, but a component that adjusts visible width according to its running content.

The SupportTools version shipped in Maple 2026.0 has a flaw that interferes with its Update command.

But it's possible to update the original SupportTools in Maple 2026, from the the MapleCloud via GUI login, or with the Maple command

    PackageTools:-Install(4797495082876928);

And that contains not just the first set of its Library fixes for 2026 but also a fix for SupportTools itself.

ps. I copied this from a response in the Beta users forum.

In 2D Input mode you can get that combination is a few different ways.

You can get it by using command-completion. For example, in 2D Input mode (the default for new users), simply type the keystrokes   Delta   and then hit the Escape key. And then once you have the Greek letter shown you can type Q, etc.

You can also get it in 2D Input mode by selecting the typeset Greek Delta from the palettes. It's available from the Greek palette. And if you'd like you can produce it alone as an output and then select&drag that to your Favorites palette.

Either of those two approaches could be used to produce the following,

Q+`ΔQ`

Q+`ΔQ`

Download Q.mw

In 1D Input mode (not the default for new users) you could enter that combination as the plaintext code,

    `ΔQ`

and you'd see the typeset Greek letter in the output.

ps. I'm not sure what you intend on the left-hand side of your assignment statement. Be careful about using Q followed by an apostrophe unless you right-click on it in the input and turn it into an Atomic Identifier (a mere name). Otherwise you might get it interpreted as a call to diff, ie. diff(Q(x),x), from the prime notation in calculus; and you wouldn't want to assign to that.

Here is a workaround that allows you to use your original call to plots:-display, without having to supply additionally a view option with a manually combined x-range.

I believe you can do this in Maple 2026.0 as well as your Maple 2024.

pic1 := plot(1-cos(t), t=0..2*Pi, coords=polar, redraw=false):
pic2 := plot(1+cos(t), t=0..2*Pi, coords=polar, redraw=false):

plots:-display(pic1, pic2, scaling=constrained);

I suspect that the coords=polar detail in the redrawing information (now stored in the plotting structures pic1,pic2) is being misused under plots:-display. Possibly it expected a polar axiscoordinates to go along with the polar coords, and which you are not using...

nb. The redrawing info was added in part as a means for plot fidelity to improve in situations where the user manually zooms into a plot. But it also gets used under plots:-display, though I'm not sure why that part had to come about. It's documented on the ?plot,options Help-page.

ps. I realize that your example was written to illustrate the issue with display. I expect that you already know that you could form the result directly in a single plot call, eg.
  plot([1-cos(t),1+cos(t)], t=0..2*Pi, coords=polar, scaling=constrained);

I would like to see plots:-setoptions allow redraw=false.

Depending on the order in which the steps are taken, it's possible to get an evaluation like tan(Pi/2) and get held up by a numeric exception. Or sec(Pi/2).

There are also some related aspects, for eval versus limit. (It might not be directly related to this example, but didn't you show some weaknesses in that regard, under dsolve, a few months ago? I mean, they can exist...)

restart;

kernelopts(version);

`Maple 2026.0, X86 64 LINUX, Mar 05 2026, Build ID 2001916`

ode:=diff(y(x),x)*sin(2*x) = 2*y(x)+2*cos(x);

(diff(y(x), x))*sin(2*x) = 2*y(x)+2*cos(x)

ic := y(1/2*Pi) = 0;

y((1/2)*Pi) = 0

K := dsolve(ode);

y(x) = c__1*tan(x)-sec(x)

CV := isolate(K,c__1);

c__1 = -(-y(x)-sec(x))/tan(x)

GV := limit(CV,x=Pi/2);

c__1 = 1

limit(K, GV);

y(x) = tan(x)-sec(x)

Download nm_ode_43.mw

So, there seems to be a limit of 10001 for either dimension, for the browser choice to appear in the context-panel.

The browser itself does not show more than about 1000 pixels wide. So numeric data is being scaled down anyway, by the browser itself.

(My monitor is not 10000 pixels wide, so I'd never be able to see such a browsed huge Matrix unless it did auto-scale behind the scenes, unless I were prepared to use the scroll-bar a great deal. Unscaled, I could never see it all at once.)

But if your Matrix contains numeric data then you yourself could apply ImageTools:-Scale to it beforehand (giving datatype=float to a copy of it, if it doesn't already have it). In such a case you could easily scale it down a max of 1000 or so in the largest dimension. And then you could browse that.

I'm not sure whether you are trying to browse it to see structure, or an "image" of it, etc.

If you scale it down to size 1000 then you could also ImageTools:-Embed that (if float[8]).

restart;

G:=proc(ee,k::posint:=2)
    subsindets(ee,`*`,
               u->`if`(irem(denom(content(u)),k)=0 and
                       member(sqrt(k),[(uu->`if`(uu::`*`,op(uu),uu))(numer(content(u)))]),
                       u*sqrt(k)/%sqrt(k),u));
end proc:

 

1/sqrt(2)*(x+a);
G( % );
value(% - %%);

(1/2)*2^(1/2)*(x+a)

(x+a)/%sqrt(2)

0

-15/sqrt(2)*(x+a) + sqrt(2) + sin(sqrt(2)/2*x);
G( % );
value(% - %%);

-(15/2)*2^(1/2)*(x+a)+2^(1/2)+sin((1/2)*2^(1/2)*x)

-15*(x+a)/%sqrt(2)+2^(1/2)+sin(x/%sqrt(2))

0

-15/7/sqrt(2)*(x+a) + sqrt(2) + sin(sqrt(2)/2*x);
G( % );
value(% - %%);

-(15/14)*2^(1/2)*(x+a)+2^(1/2)+sin((1/2)*2^(1/2)*x)

-(15/7)*(x+a)/%sqrt(2)+2^(1/2)+sin(x/%sqrt(2))

0

1/sqrt(3)*(x+a);
G( %, 3 );
value(% - %%);

(1/3)*3^(1/2)*(x+a)

(x+a)/%sqrt(3)

0

-13/7/sqrt(5)*(x+a) + sqrt(5) + sin(sqrt(5)/20*x) - P(1/sqrt(5));
G( %, 5 );
simplify(% - %%);

-(13/35)*5^(1/2)*(x+a)+5^(1/2)+sin((1/20)*5^(1/2)*x)-P((1/5)*5^(1/2))

-(13/7)*(x+a)/%sqrt(5)+5^(1/2)+sin((1/4)*x/%sqrt(5))-P(1/%sqrt(5))

0

Download unrat01.mw

The word stylesheet is an option of the GraphTheory:-DrawGraph command.

The term Style Set relates to customized character/paragraph attributes, and files to manage them.

In Maple 2026, see the Edit tab in the ribbon, which contains two items:
    Styles
    Manage Style Sets

You can get to the documentation for Style Sets with a query on styleset .

 

ps. If you query just style in the Help-system then the item for this appears a little too far down for my taste.

The What's New pages show for that latest version that the Online Help has been updated.

But the older What's New pages are also there, with a somewhat standarized naming scheme, reflecting that of Topic names in the Help system of Maple proper. 

So it seems like one could query and see which is the highest such that's present.

restart;

for i from 2022 to 2026 do
  if not HTTP:-Get(cat("https://www.maplesoft.com/support/help/Maple/view.aspx?path=updates/v",i))[1]=200 then
    V := i-1; break;
  end if;
end do;
V;

2025

Download online_ver.mw

I don't know when they'll be updated next, or the answers for your two queries 1), 2).

If continuity in a solution is important to you (for, say, real x),

restart;

kernelopts(version);

`Maple 2026.0, X86 64 LINUX, Mar 05 2026, Build ID 2001916`

ode:=x*diff(y(x),x) = y(x)*cos(ln(y(x)/x));

x*(diff(y(x), x)) = y(x)*cos(ln(y(x)/x))

dsolve(ode,y(x)) assuming x>0, y(x)/x>0; # Alfred_F

y(x) = exp(2*arctan(1/(ln(x)+c__1)))*x

That solution can also be obtained with just,
S1:=dsolve(ode,y(x)) assuming x>0, real;

y(x) = exp(2*arctan(1/(ln(x)+c__1)))*x

simplify(eval((lhs-rhs)(ode),S1)) assuming x>0, real;

0

odetest(S1, ode);

0

In Maple 2024.2 odetest can get zero with,
#simplify(evalc(convert(odetest(S1, ode),expln))) assuming x>0, real;

plot(eval(rhs(S1),c__1=0), x=0..2, size=[500,200], thickness=3, color=red, view=0..40);

That portion for 0<x<1 is not zero
plots:-display(%, view=0..1);

S2:=simplify(evalc(convert(dsolve(simplify(convert(ode,arctan)),y(x)),expln))) assuming x>0, real;

y(x) = x*exp(Pi+2*arctan(-ln(x)+c__1))

simplify(eval((lhs-rhs)(ode),S2)) assuming x>0, real;

0

odetest(S2, ode);

0

In Maple 2024.2 odetest can get zero with,
#simplify(evalc(convert(odetest(S2, ode),expln))) assuming x>0, real;

plot(eval(rhs(S2),c__1=0), x=0..2, size=[500,200], thickness=3, color=blue, view=0..40);

plot3d(eval~(y(x),[S1, S2]), x=0..2, c__1=-1..1,
       grid=[100,100], color=[red,blue],
       orientation=[70,75,0], size=[400,400]);

These might even be "ok" for x<0, (by some defn of "ok", eg. satisfying
the ode but not real-valued, etc)

Digits:=30:
plot3d(abs~(eval~((lhs-rhs)(ode),[S1, S2])), x=-10..10, c__1=-10..10,
       color=[red,blue], orientation=[-45,75,0], size=[500,400]);
Digits:=10:

Download nm_ode_x.mw

Try the location documented on the Help-page for the user's preferences file.

[edit] Btw, did the site from which you downloaded the installer have a checksum listed for the installer file? Slim chance, but might be worth a check.

The default for Normalizer is that it just calls normal. That is not strong enough in the case of your example that contains exact radicals.

If the exact radicals are removed by applying evalf, then your example runs ok.

If Normalizer is set to something strong enough then your example runs ok. Eg,
    Normalizer := simplify:

inscribe_circle_ac.mw

Note that Testzero calls Normalizer. This pair are key in some linear-algebra kind of operations (eg. finding valid pivots, etc.) Failing to correctly notice a "hidden" zero, due to a weak test, is a classic problem. I haven't yet looked for the particular code line(s) where your example goes awry under simplex, but this kind of issue is not unheard of.

Optimization uses just floats, so it doesn't see this particular issue in the case of radicals. Some things like LinearAlgebra:-LUDecomposition make an attempt at temporarily strengthening Normalizer depending on the nature of the exact expressions found. But not all older commands do.

It seems that the expanded ln term on the rhs is the problem.

By utlizing combine on that term, either solve or RealDomain:-solve can be used.

These work quickly,

restart;

kernelopts(version);

`Maple 2025.2, X86 64 LINUX, Nov 11 2025, Build ID 1971053`

eqn := ln((y-1)^(1/3)*(y^2+y+1)^(1/3))-ln(y) = 2/5*ln(t^2+1)+_C;

ln((y-1)^(1/3)*(y^2+y+1)^(1/3))-ln(y) = (2/5)*ln(t^2+1)+_C

 

A := simplify({ solve(combine(eqn), y) });

{(-(-1+(t^2+1)^(6/5)*exp(3*_C))^2)^(1/3)/(-1+(t^2+1)^(6/5)*exp(3*_C)), (-(-1+(t^2+1)^(6/5)*exp(3*_C))^2)^(1/3)*(I*3^(1/2)-1)/(-2+(2*t^2+2)*exp(3*_C)*(t^2+1)^(1/5)), -(-(-1+(t^2+1)^(6/5)*exp(3*_C))^2)^(1/3)*(1+I*3^(1/2))/(-2+(2*t^2+2)*exp(3*_C)*(t^2+1)^(1/5))}

 

select(is, simplify(A), real)[] assuming real;

-((-1+(t^2+1)^(6/5)*exp(3*_C))^2)^(1/3)/(-1+(t^2+1)^(6/5)*exp(3*_C))

 

new := combine((lhs-rhs)(eqn)) assuming real;

ln(((y^2+y+1)*(y-1))^(1/3))-ln(y*(t^2+1)^(2/5))-_C

simplify( RealDomain:-solve(new, y ) );

(-(-1+(t^2+1)^(6/5)*exp(3*_C))^2)^(1/3)/(-1+(t^2+1)^(6/5)*exp(3*_C))


Note:

(2*ln(t^2 + 1))/5;
combine(%);
%; # evaluation re-expands it

(2/5)*ln(t^2+1)

ln((t^2+1)^(2/5))

(2/5)*ln(t^2+1)

Download nm_solve_01.mw

1 2 3 4 5 6 7 Last Page 2 of 344