## How can I create a well-formatted PDF when using t...

Hello

I need to share some results with a colleague who is not a user of Maple, and a way to do this is by using the Tabulate (plain command and not from DocumentTools) function to format them. In the worksheet, the output looks good, but when I try to print it or save it as a PDF, only a few lines are printed. It appears that Maple is not able to break the tables into multiple pages for printing.

The output is a table with 77 rows and 30 columns.

I welcome alternative solutions to the problem of displaying the results.

Many thanks

## what is the easiest way to find a row in matrix...

This is probably a dummy question. I have a matrix (3 columns, 4 rows). I would like to extract the rows in which the value in the third column matches "2". As long as one has a matrix of 2 columns, this can be easily done by using the Lookup command but it does not allow you to give the row values of multiple columns. Is there another command that allows you to do that?

FindRowInMatrix.mw

## Space-time de Sitter solution...

I am trying to calculate the line element ds^2, for a de Sitter spacetime in 2+1 dimensions with positive cosmological constant, using the following metric and energy moment tensor:
1- ds² = -A(r) c^2 dt^2 + B(r) dr^2 + r^2d{\theta}^2,
2- T^{\mu \nu} = -(\rho + p) dx^{\mu} dx^{\nu} + p g^{\mu \nu}.

I tried several ways but I can't solve it using Maple 2023, Physics package. Could someone show me step by step how to solve this problem?

Images of the line element we need to find, the metric tensor associated with the problem and the components of the Riemann tensor.
My goal is to calculate the metric tensor, line element and associated components of the Riemann tensor for De Sitter spacetime with positive cosmological constant.

## How to simplify assuming real domain?...

Question deleted since it tagged duplicate. Will go search for the duplicate. I did not know there was duplicate one.

update

Here is original question. If moderator thinks it is duplicate feel free to delete.

I would like to duplicate this simplification done in Mathematica, but in Maple. Mathematica will cancel the exponential term automatically if told the domain is real, but in Maple it willl not.

My attempts in Maple which all fail

restart;

ode := diff(v(x), x, x)*exp(x^2) = 0;
simplify(ode);
simplify(ode) assuming real; #there is no such type
simplify(ode) assuming x::positive;
simplify(ode,symbolic);
use RealDomain in simplify(ode) end use;


How to cancel the exponential term from the above equation in Maple?

## How to insert the notation of a vector, with an ar...

Hi,

How to insert the notation of a vector, with an arrow? thanks

S5VecteurTextPlot.mw

evalf(Pi*int(2*299792458^2*662607015*10^(-8)*10^(-34)/((exp(299792458*662607015*10^(-8)*10^(-34)/(1380649*10^(-6)*10^(-23)*lambda*5772.0)) - 1)*lambda^5), lambda = 0 .. infinity));

returns a complex number for the Solar radiant exitance in watts per square meter with an effective blackbody temperature of "5772.0" kelvins.

Replacing "5772.0" with an exact "5772" gives the correct answer though.  The nominal Solar temperature is defined as exactly 5772 kelvins whereas the physical Solar effective temperature is 5772.0 K (+/-) 0.8 K.

Is there a way to get Maple 2023 to avoid outputting these types of errors when using nonexact quantities?

I tried replacing "5772.0" with "5772.00000000001" and "5771.9999999999" and the error is not duplicated for those kelvin temperatures.

Interestingly, this error does not occur on Maple for Excel, only within the Maple desktop client....

https://scienceworld.wolfram.com/physics/Stefan-BoltzmannLaw.html

https://iopscience.iop.org/article/10.3847/0004-6256/152/2/41/

## How to simplify Maple expressions that involve pro...

I'm currently addressing a problem related to modified Bessel functions using an older version of Maple (the specific version escapes my memory). In an attempt to resolve issues, I've experimented with the trial version of Maple 2023, but I've encountered an unusual phenomenon. Expressions that were previously simplifiable in Maple now resist simplification. The specific expression provided below, which should equate to 1, fails to be recognized as such by Maple. This poses a concern as it could lead to overly complex expressions in subsequent steps, considering this expression is only an intermediate stage. Is there a recommended approach to overcome this challenge?

## How to efficiently implement the addition of a mon...

Hello

I could not come up with a better title, so I apologize for that.  Let me explain what I am trying to implement using an example.

Consider the following list of monomials (a 3D model,  4 monomials altogether):

model := [x^2*y*alpha[1, 11], x*z^2*alpha[2, 15], y^2*z*alpha[3, 17] + y*z*alpha[3, 8]]

The idea is to generate the set of all models by adding a non-repetitive monomial from the following list to model.

[alpha[i, 0], alpha[i, 1]*x, alpha[i, 2]*y, alpha[i, 3]*z, alpha[i, 4]*x^2, alpha[i, 5]*y*x, alpha[i, 6]*z*x, alpha[i, 7]*y^2, alpha[i, 8]*z*y, alpha[i, 9]*z^2, alpha[i, 10]*x^3, alpha[i, 11]*y*x^2, alpha[i, 12]*z*x^2, alpha[i, 13]*y^2*x, alpha[i, 14]*z*y*x, alpha[i, 15]*z^2*x, alpha[i, 16]*y^3, alpha[i, 17]*z*y^2, alpha[i, 18]*z^2*y, alpha[i, 19]*z^3]

where i indicates the coordinate where the monomial will be included.  Example: if alpha[i, 2]*y is to be added to the second coordinate of model it goes as alpha[2,2]*y. Note that alpha[i, 15]*z^2*x cannot be added to coordinate 2 since it is already there.

The result will be a list of 56 models with 5 monomials.

How can I do that efficiently?

Many thanks

Ed.

PS. I have implemented something similar to the problem above, but I have used too many 'for' loops.

## Scan Math with Maple Calculator and Show Steps...

Maple 2023 , Maple Calculator

[Right-click on image and open in new tab to see larger]

To Scan Math with the Maple Calculator and show solution steps in Maple:

1. first scan some math with the calculator

2. Maple calculator immediately shows the solution if that is what you are looking for:

3. Calculator gives options to show the solution steps in the calculator itself ( footprint button in top-right)

4. Or to upload the math to the MapleCloud (cloud icon with up arrow)

5. Once the math is uploaded, MapleCloud can be loaded on a desktop computer and the file opened from your account's Maple Calculator group of files:

6. Again, the solution and some more details are visible on Maple Cloud:

7. To open this math in Maple, click the blue button to Download the file.

8. The Maple commands to solve this math are shown, and the result.

To show steps in Maple at this point, convert the math to inert form, then run the Student:-Calculus1:-ShowSolution() command on it:

 (1)

Integrate

The solution to this integral is:

 (1.1)

 (2)

## how to convert RootOf to a proper radical form...

I have a result:

u1 = RootOf(4*_Z^2 + (4*RootOf(60*_Z^3 - 60*_Z^2 + 15*_Z - 1) - 4)*_Z + 4*RootOf(60*_Z^3 - 60*_Z^2 + 15*_Z - 1)^2 - 4*RootOf(60*_Z^3 - 60*_Z^2 + 15*_Z - 1) + 1)

but it reported error Error, (in sprintf) too many levels of recursion

how can I convert it to this form?

Thanks!!

by: Maple 2023

There appears to be a bug with Maple 2023.2 which will remove units from physical constants.

AddConstant(Solar_equatorial_radius, symbol = r[e,Sol], value = 696342., uncertainty = 65., units = km) :

AddConstant(Solar_flattening, symbol = f[Sol], value = 0.000009) :



In the example here, "GetUnit(Constant(r[p,Sol]))" will return "1" and "GetUnit(Constant(x[Sol]))" will return "m".

The only workaround is to not save dimensionless quantities as physical constants or otherwise at least some constants derived from a dimensionless constant will also be dimensionless.

## Numerical bug in Maple 2023 when increasing Digits...

Hello! We are using Maple to evaluate numerically expressions with very high precision and we are finding very strange results. After some playing with simple models we have come to conclusion that there might be a bug in Maple 2023. Here is a clean example of what we are experiencing. Plotting the function x*exp(-x) in [0,20]. Clearly the function cannot be negative in that interval! However, if Digits is set to 40 the results may be whatever. Any ideas? Thank you very much.

## Remove unit symbol?...

Is there a way to remove a unit symbol?  "AddUnit" allows to add additional symbols or change the default symbol, but I don't see any way to remove symbols?

A good example is for the hectare.  Maple 2023 uses "a" as the default symbol for the are, except that the unit symbol "a" does not allow using SI prefixes because the peta- unit prefix then conflicts with the pascal ("Pa").  I can use "AddUnit" to change the default symbol for the are from "a" to "are" but I still cannot enable SI prefixes unless the symbol "a" is removed from the symbol set.  This way hectares ("hare") and petares ("Pare") can be used.

I don't see a way to nondestructively/temporarily delete units either ("RemoveUnit").  Deleting the unit "are" and then recreating it as a new unit with the symbol "are" would solve the same problem.

I just saw that there already exists a separate "hectare" unit with the symbol "ha" which presumably also needs to be removed in order to enable SI prefixes for "are".  This is just one example but a general way to remove units and/or unit symbols should be very helpful.

## Import MPL from URL?...

Is there a way to import an MPL file from a URL?

Import("https://www.nicolesharp.net/testbox/test.mpl");

Using the "Import" command on Maple 2023.2 appears to only import the MPL as plaintext and doesn't recognize any of the Maple instructions from the MPL file.

Using the "Get" command with the URL package doesn't do anything useful either.

with(URL) : Get("https://www.nicolesharp.net/testbox/test.mpl");

## is this new bug in integrate? (in IntegrationTools...

Any one knows if this is a new bug in int()? It happens only when kernelopts('assertlevel'=2): is on.

Using Maple 2023.2.1 on windows 10.

edit: Found another integral. #3 below. The difference now is that this third integral is solved completely when removing Physics update/lib from libname. While the first two are not solved. But all three now do not give exception with the updated libname. New attachment is below.

ps. just in case I also just send bug report to Maplesoft.

 > restart;

 > interface(version)

 > Physics:-Version()

 > kernelopts('assertlevel'=2):
 > integrand:=(-b*x+a)^(4/3)*(b*x+a)^(8/3); int(integrand,x,method=_RETURNVERBOSE);

Error, (in IntegrationTools:-Indefinite:-ExpandAndMapOverSums) assertion failed, Invalid input for ExpandAndMapOverSums

 > integrand:=(-b*x+a)^(4/3)*(b*x+a)^(4/3); int(integrand,x,method=_RETURNVERBOSE)

Error, (in IntegrationTools:-Indefinite:-ExpandAndMapOverSums) assertion failed, Invalid input for ExpandAndMapOverSums

 > integrand:=(-b*x^2+a)^(3/2)*(b*x^2+a)^(3/2); int(integrand,x,method=_RETURNVERBOSE)

Error, (in IntegrationTools:-Indefinite:-ExpandAndMapOverSums) assertion failed, Invalid input for ExpandAndMapOverSums

 > libname

 > restart;

 > libname:="C:/Program Files/Maple 2023/lib"

 > kernelopts('assertlevel'=2): integrand:=(-b*x+a)^(4/3)*(b*x+a)^(8/3); int(integrand,x,method=_RETURNVERBOSE);

 > integrand:=(-b*x+a)^(4/3)*(b*x+a)^(4/3); int(integrand,x,method=_RETURNVERBOSE)

 > integrand:=(-b*x^2+a)^(3/2)*(b*x^2+a)^(3/2); int(integrand,x,method=_RETURNVERBOSE)