## How to define, in a module, a typesetting rule to ...

Dear All,

I'm wondering if there is a simple way to define, given a "module" that protects "e" as a global, to allow the user to write e[0], e[1], e[2], e[3], e[inf] such that I calculate with e[4] but I display e[inf]. And if I type in e[inf], it translates behind the curtain of the module e[inf] into e[4] such that I keep my indexes 0-4 for the handling of my entities.

I hope I made myself understood ;)

I was woundering if there is some way with the standard "TypeSetting Module" ?

Sincerely

Ivar

## Sparse matrixplot with column labels: Is that poss...

How can I achieve something like this (i.e. an output in a worksheet)?

It is important that the variables of the lables match the columns.

In the attached file is a typical dataset. A display of row lables would be optional.

Context: Easier interpretation (of the structure) of a Jacobian and subsequent manual solving the equations of interest that correspond to the rows.

Labels_for_sparse.mw

## Show Solution to Nonlinear Partial Differential Eq...

Hi!

I would like Maple to show the full solution method to this pde.  How do I do this?

Show_Solution_to_NLPDE.mw

## How to integrate...

Hello my friends
Please help me solve the integration problem in the attached Maple code below (why was the integration not done in u[4]?) ... Thank you very much

 > u[1] :=  1/3*t^3*x + 2*t*x + (-1)*0.7522527780*t^(3/2)*x + (-1)*0.1719434922*t^(7/2)*x + (-1)*0.01587301587*t^7*x + (-1)*0.1333333333*t^5*x
 (1)
 > u[2] := subs(t=Tau,u[1]);
 (2)
 > u[3]:= int(u[2],Tau = 0 .. t);
 (3)
 > u[4]:= int((t-Tau)^(-0.5)*u[2],Tau = 0 .. t);
 (4)

## Tubeplot colors...

When displaying two tubeplots together, we may specify their colors at will, as long as they are different colors!  For instance, specifying red and green works correctly, but specifying red and red results in red and black!

See the attached worksheet.  Interestingly, when displaying the contents of the worksheet on this website, the colors are rendered correctly!  So don't go with what you see on this web page; look inside the worksheet instead.

 > restart;
 > kernelopts(version);

 > with(plots):

Two intersecting tori colored red and green -- works as expected:

 > display(         tubeplot([cos(t), 0, sin(t)], t=-Pi..Pi, radius=0.2),         tubeplot([cos(t), sin(t), 0], t=-Pi..Pi, radius=0.2), style=surface, color=[red,green]);

When we set both colors to red, one of the surfaces is painted black!  Why?

Please note: This website displays the colors corectly as red and red.  But

within the worksheet the colors are read and black.

 > display(         tubeplot([cos(t), 0, sin(t)], t=-Pi..Pi, radius=0.2),         tubeplot([cos(t), sin(t), 0], t=-Pi..Pi, radius=0.2), style=surface, color=[red,red]);

Specifying colors as red/red within the tubeplots still produces red/black!

 > display(         tubeplot([cos(t), 0, sin(t)], t=-Pi..Pi, radius=0.2, color=red),         tubeplot([cos(t), sin(t), 0], t=-Pi..Pi, radius=0.2, color=red), style=surface);

PS: As a workaround, we may replace the red & red specification with
COLOR(RGB, 1, 0, 0) and
COLOR(RGB, 1, 0, 0.01)
which are different enough to make Maple happy, but produce essentially the same red color.

## NLPsolve non numeric result...

Hello everyone,

I am trying to solve a simple nonlinear 4 variable function with NLPsolve giving real values ranges for the variables but the NLPsolve gives "non numerical" result. Find attached the worksheet.CoreOptimization.mw

Am I doing something wrong?

Regards,

Cata

## Extract variable "x" to one side...

I have a mixture function of power fractional along with natural log, where both contain x variable. Can I use Maple to extract the x variable to one side of the formula?

## why Maple give completely different result for ode...

What is the correct way to write the explicit solution before calling odetest to verify it on an ode? is it

sol:= y(x)= the RHS  (1)

or

sol:= y(x) - the RHS = 0 (2)

I am asking because Maple sometimes gives very different result from odetest depending on which form the explicit solution is written. It is very hard to keep trying different forms each time.  Here is an example below.

Maple 2022.1 on windows 10.   Is this a bug? I do not think it should  make a difference, but it does and I have no idea why. Is there an option or way to make sure the same result is obtained each time regardless how the explicit soltion is written?

I have a theory as to why this might happen: When using (1) odetest sees y(x) on the LHS on its own, and then uses odetest  code internally designed for explicit solution testing.

When using (2), it sees y(x) not on its own on the LHS and it assumes this is then an implicit solution and uses odetest code internally meant for implicit solution testing, hence the difference in output.

 > restart;
 > ode:=sqrt(y(x))+(1+x)*diff(y(x),x)=0: ic:=y(0) = 1: mysol:=y(x)=1/4*(ln(1+x)-2)^2: odetest(mysol,ode);

 > odetest((lhs-rhs)(mysol) = 0,ode);

 >
 >

## Writing a function to get a Random planar graph...

Any way to write a function to get a RandomPlanar connected graph

That I have function say RandomPlanar(n,m) where n is the number of vertices and m is optional parameter and is the number of edges

## Find if all rows in the matrix are unique...

How to find if all the rows in a matrix are unique and return true if unique and false if not

That is their are no duplicate rows

Also without another post

If given two matricies A and B how to find if they are same like what i mean is as equal here is

A and B have the same rows but they may be in rows can be jumbled imples

A:=Matrix(3, 3, [[1, 2, 3], [3, 2, 1], [4, 6, 5]])

B:=Matrix(3, 3, [[3, 2, 1], [1, 2, 3], [4, 6, 5]])

They have the same rows exactly but in jumbled order then I say they are equal then return true.

That is i have function RowEqual(A,B) gives TRUE if same by above condition and FALSE is not

## Font-size of caption, labels and axes on plots sma...

Maple 2021.
I expect after exporting to pdf view of page with plot like on fig. 1.

It means with font=[TIMES, ROMAN, 12] as in maine text.
But I obtaned this view of page on pdf (fig. 2) with smaller font-size.

In previouse versions there are no the problem like this.
Dear community, how to fix this annoying inconvenience?

fig. 1.  fig. 2.

## Browse matrix by command: Is that possible?...

What I want to achieve with a command is the following image, in which the elements of a matrix that are not zero are displayed in black

This can be accomplished with the Browse Matrix Dialouge, but I want to make such images part of the worksheet. (Display of the full matrix is important.)
Context: Re-execution of worksheets will allow for quick verification of changes in Jacobians.

## Efficient and accurate way to find intersection po...

I have a closed curve(parameterized by t) with self intersection and I'd like to locate the x-y coordinates of the intersection. fslolve only returns 1 intersection. I've tried to use a finite step method but it is way to slow even with rough stepping and becomes very inaccurate. Does maple have anything built in to handle this?

## Help writing code...

Hello my friends
How can I write the results inside the Maple code as in the picture? That is, writing the results in terms of gamma and alpha