## Will Maple work on Pine laptop with Arm cpu?...

Is the linux version of Maple architecture dependent?

## Error, (in dsolve/numeric/BVPSolve) argument #4, t...

Hi everyone, I have a problem in the code solving coupled partial differential equations. I could not find out the solution. Please help me out with this. Find the code in the attachment.

## 2nd derivative implicit differentiation...

I didn't understand what the page on implicit differentiation meant by 2nd derivatives are just like in using diff    Like this  implicitdiff(y^2 = x^3+a*x+b, y, x, [x\$n]) ??  idk

## Using Maple to solve a Second Order ODE...

I have the following ODE which I would like to solve with Maple rather than solving by hand (having solved this type of equation by hand many times now):

diff(f(x,y,z),z\$2) = A - B*e^(-A*z)

where A and B are constants and I have indicated the second derivative of a function of x,y and z with respect to z.

## Plot is not matching...

Dear maple users,
Greetings.
I am solving an ode problem with an analytical solution.
programming running properly, but my plot not exact with the already existing article plot.
how to get the exact plot.

Thanking you.

Code:JVB.mw

 >
 >
 (1)
 >
 (2)
 >
 (3)
 >
 (4)
 >
 (5)
 >
 >
 >

Analytical solution approach:

## supremum of function ...

Dear all

I hope to find the supremum of the sequence of the function using maple 18, but when I run the code there is no results

maximize.mw

Many thanks

## Solving a linear system of equations different fro...

Dear,

If we have to solve in Maple a linear system like A.x =b, we employ the command Linsolve. However, how can I solve a system like x.A=b?

The only method I know is to compute x=b.A-1. Is this an efficient method or there is a better one you recommend?

## Why do I get different result in maple and python?...

phi:=(j,x)->piecewise(j=0,exp(x),1/(j-1)!*Integrate(exp((1-theta)*x)*theta^(j-1),theta=0..1))

I want 15 digits after the dot, so I set Digits:=15

phi(j,x)=0.167084168060000

Doing the same in python I receive

0.16708416805754214

## A strange behaviour of the display...

Hi,

Here are two sequences of commands that should give the same kind of plots. But, while the first one returns the expected display, the second doesn't (look to the labels on the histogram plot).

There is no hidden character that could explain this second display. Just that I proceeded this way:

1. I executed the second sequence once.
2. Then I told myself that displaying the histogram was superfluous, so I replaced its final semicolon with a colon.
3. And I finally thought that, no, the histogram had a real interest and that I should display it; and I restored the semcolon (this is what you can see on the second sequence).
And this add to the histogram the labels inherited from the second plot ...

Nothing dramatic here, but was the development team aware of this curiosity?

 > restart:
 > N := 10: S := Statistics:-Sample(Normal(0, 1), 10)^+: Statistics:-Histogram(S); plots:-logplot(<  < [\$1..N]> | S >, labels=["A", "B"]);
 > restart:
 > N := 10: S := Statistics:-Sample(Normal(0, 1), 10)^+: Statistics:-Histogram(S); plots:-logplot(<  < [\$1..N]> | S >, labels=["A", "B"]);
 >

## How can I plot a function from higher to lower val...

My question deals with plotting a function, namely, x(t), from lower to higher values of t.

To this aim, I solved a simple differential equation with given initial conditions and then plotted for the result.

As it is seen, maple starts from lower values of t to higher ones. However, is there a command through which I can reverse the plotting procedure?

From the attached file, "A question on plotting", we see that the slope of the curve at t=2 is positive when we observe it from "left to right". However, this slope is negative once we start plotting from "right to left".

Is there any command with which I can start plotting from right to left? or change of axis origin?

I would appreciate for your kind help and support.

My best regards

## Remove Big O terms...

(D@@2)(T)(0) + :-O(1) + 1/2*sin(1/2*Pi*T(x))^2 + 1/12*sin(1/2*Pi*T(x))*Pi*diff(T(x), x)*cos(1/2*Pi*T(x)) + :-O(2/3*(3/2*Pi^2*diff(T(x), x)*cos(1/2*Pi*T(x))^2*diff(T(x), x, x) - Pi^3*diff(T(x), x)^3*cos(1/2*Pi*T(x))*sin(1/2*Pi*T(x)) + sin(1/2*Pi*T(x))*Pi*diff(T(x), x, x, x)*cos(1/2*Pi*T(x)) - 3/2*sin(1/2*Pi*T(x))^2*Pi^2*diff(T(x), x, x)*diff(T(x), x))/Pi^2)

How can I remove the Big O terms from an expression?

## Frustrating evaluation order derails animating cur...

Dear Maplesoft,

I inquired about this problem 4 years ago, but never really was able to fix my problem based on the response at the time. This has to do with plotting a parametrized curve where the parametrization involves the numerical solution of a condition.

Consider the family of cardioids
"r = 1 + c*sin(theta), theta = 0 .. 2*Pi"
in polar coordinates for
"c = 0 .. 2.5"

In this example we find the polar angle
"theta(c)"
on the evolving family of cardioids where the slope is
"-1"
as a function of the shape parameter
"c"
of this family by a procedure involving fsolve, but then try to plot the parametrized curve
"r(c) = 1 + c*sin(theta(c))"
. No direct plotting method works because of evaluation order problems that I do not understand. The first plot is my desired plot but I used an ugly workaround to get the gray curve. Can you fix the direct method with delayed evaluation or something?

Maplesoft Response. We don't help with this kind of problem. Ask MaplePrimes.

This evaluation order problem pops up every time you want to plot a curve determined by numerically solving a condition, yet Maplesoft seems to think this is too sophisticated a problem to respond to. Naively trying to animate such curves always derails, so it reveals a weakness of Maple for users who do not belong to the elite class of Maple experts. I have been using Maple for a quarter century, and have made some pretty intricate animations and plots over the years, but always run up against this problem with animating numerically determined curves. Is there a Maple pro out there who can help?
Since I can't find a way to attach my Maple worksheet, here is the URL:
http://www34.homepage.villanova.edu/robert.jantzen/maple/misc/cardioidfamily.mw

## Plotting inequalities in 3d...

Hi, I have the following problem:

I want to plot the cone given by 1/16*(3x^2+10xz+3z^2-16y^2) and x>=0, z>=0. I tried it with

implicitplot3d([1/16*(3*x^2+10*x*z-16*y^2+3*z^2), x >= 0, z >= 0], x = -5 .. 15, y = -15 .. 15, z = -5 .. 15, grid = [30, 30, 30], style = surface);

But the result is one surface for each inequaility and not the cone.

If i restrict the range of x and z to be 0..15 and dismiss the additonal inequalities, a big part of the cone surface is missing somehow:

Does anybody know how to fix this? Do I have to use another plotcommand?

## How to make this procedure more efficient?...

Hi,

This thread is more or less related to a previous one about the Statistics:-Sample procedure.
(see https://www.mapleprimes.com/questions/228421-A-Serious-Problem-With-StatisticsSample )
I've just implemented two variant of the Box-Muller procedure to sample normal rvs.
The source is "The art of computer programming", Donald E. Knuth, 2nd edition, p117 (aka "algorithm P").

The first implementation (BoxMuller_1) is basically what D.E. Knuth writes, except that I "vectorize" some operations in order to avoid using an if.. then..else structure (as a minor consequence I generate a little bit more numbers than required).
This procedure uses the build-in Maple's procedure select (please see the link above and acer's and carl love's replies).
It appears to be relatively slow.
More of this CodeTools:-Usage(BoxMuller_1(10^6)) generates a "conenction to kernel lost" for some unknown reason.

The variant named BoxMuller_2 uses sort and ListTools:-BinaryPlace instead of select.
Ir appears to be around 3 times faster than BoxMuller_1, but remains 10 time slower than Statistics:-Sample(..., method=envelope) (here again, see the link above to understand why method=envelope is needed).

I wonder how it could be possible to speed up this procedure. In particular acer showed in one of his reply (again see the link above) how using hfloats can improve the efficiency of a procedure, but I'm very incompetent on this point.
Does anyone have any idea?

PS: this file has been written with Maple 2015.2

 > restart:
 > BoxMuller_1 := proc(N)   local V, S, T, L, X1, X2:   V  := Statistics:-Sample(Uniform(-1, 1), [ceil(2*N/3), 2]):   S  := V[..,1]^~2 +~ V[..,2]^~2;   T  := < subs(NULL=infinity, select(`<`, S, 1)) | V >;   T[.., 1]  := (-2 *~ log~(T[.., 1]) /~ T[.., 1])^~(0.5);   X1 := select[flatten](type, T[.., 1] *~  T[..,2], 'float');   X2 := select[flatten](type, T[.., 1] *~  T[..,3], 'float');   return : end proc: BoxMuller_2 := proc(N)   local V1, V2, S, W, u, r, T, X1, X2:   V1 := Statistics:-Sample(Uniform(-1, 1), ceil(2*N/3)):   V2 := Statistics:-Sample(Uniform(-1, 1), ceil(2*N/3)):   S  := V1^~2 +~ V2^~2;   W  := sort(S, output = [sorted, permutation]):   u  := ListTools:-BinaryPlace(W[1], 1);   r  := [\$1..u]:   T  := (-2 *~ log~(W[1][r]) /~ W[1][r])^~(0.5);   X1 := T *~ V1[W[2][r]];   X2 := T *~ V2[W[2][r]];   return ^+: end proc:
 > CodeTools:-Usage(Statistics:-Sample(Uniform(-1, 1), 10^5)): CodeTools:-Usage(Statistics:-Sample(Uniform(-1, 1), 10^5, method=envelope)): # CodeTools:-Usage(BoxMuller_1(10^6)): # generates a "connection to kernel lost" error msg CodeTools:-Usage(BoxMuller_2(10^6)): print(): CodeTools:-Usage(BoxMuller_1(10^5)): CodeTools:-Usage(BoxMuller_2(10^5)): print(): S1 := BoxMuller_1(10^5): S2 := BoxMuller_2(10^5):
 memory used=1.17MiB, alloc change=0 bytes, cpu time=12.00ms, real time=12.00ms, gc time=0ns memory used=3.32MiB, alloc change=32.00MiB, cpu time=64.00ms, real time=64.00ms, gc time=0ns memory used=148.17MiB, alloc change=119.93MiB, cpu time=706.00ms, real time=637.00ms, gc time=14.63ms
 memory used=67.43MiB, alloc change=186.80MiB, cpu time=946.00ms, real time=762.00ms, gc time=285.14ms memory used=14.81MiB, alloc change=0 bytes, cpu time=67.00ms, real time=62.00ms, gc time=0ns
 (1)
 > if false then DocumentTools:-Tabulate(   [     plots:-display(       Statistics:-Histogram(S1),       plot(Statistics:-PDF(Normal(0, 1), x), x=-4..4, color=red,thickness=3)     ),     plots:-display(       Statistics:-Histogram(S2),       plot(Statistics:-PDF(Normal(0, 1), x), x=-4..4, color=red,thickness=3)     )   ], width=60 ) end if:
 > # carl love's procedure with slight modifications t SampleCheck := proc(X, f, N::posint) uses St= Statistics;   local S, M, O, E:   S:= f(N):   M:= numelems(S):   O:= )>:   E:= St:-Probability~(X <~ (rhs@lhs)~(O), 'numeric') * M:    end proc:
 > interface(rtablesize=20): SampleCheck(Statistics:-RandomVariable(Normal(0,1)), 'BoxMuller_1', 10^5), SampleCheck(Statistics:-RandomVariable(Normal(0,1)), 'BoxMuller_2', 10^5);
 (2)
 >