MaplePrimes Questions

For compact technical documentation it would be desirable to create output in the form of a=b=c, which is a style that is commonly used in textbooks (probably for the same reason).

It is possible to create such an output with non executable math and probably also with document blocks. This is error prone and time consuming. I am looking for a solution where I can use Maple commands to refer to expressions to assemble an a=b=c output.

The advantage: Using commands would change the output when the expression change (at least after re-execution of the document).

How can this be done?

I'm attempting to use the GoogleMaps command however it doesn't appear to work

FindLonLat("Waterloo") just returns the command.  What now?

Colored axes and showing 5 colored branches (Riemann surfaces) and ln(z)  as a spiral

There is a plotcompare(log(z), expression_plot, 3); branches(ln);

FunctionAdvisor(branch_cuts, log(z));
                         [ln(z), z < 0]

The principal branch is the red colored one : Pi..-Pi (difficult to see here )


                                       pic 1

Compare this pic 1  with the Imaginaire plot log(z) in plotcompare command.

Hi,

Happy new year.

I have a problem, if it is possible please guide me.

I want to add "arrows=small/curve/...." (i.e. vector fields) to the following maple's example, but unfortanutley it does not work (see the green code and run it ....).

It is not important to me that I use phaseportrait or DEplot or dfieldplot, I just want to show arrows in any "scene" that I choose.

restart;

with(plots);
with(DEtools);
with(VectorCalculus);
BasisFormat(false);

DEplot({D(w)(t) = x(t) - w(t)*z(t), D(x)(t) = y(t) + z(t), D(y)(t) = -x(t) - y(t) + w(t), D(z)(t) = x(t) + y(t) - z(t)}, [x(t), y(t), z(t), w(t)], t = 0 .. 10, [[x(0) = 0, z(0) = 0.25, y(0) = 0.5, w(0) = 0.165]], scene = [z(t), w(t)], numsteps = 101, axes = BOXED, linestyle = dashdot, method = rkf45, startinit = true, maxfun = 5000, xtickmarks = 10, arrows = medium);

Indeed I want to get something like this:

DEplot([diff(x(t), t) = -0.5*x(t)*y(t), diff(y(t), t) = 0.5*x(t)*y(t) - 0.15*y(t)], [x(t), y(t)], t = 0 .. 40, x = 0 .. 1, y = 0 .. 0.6, [[x(0) = 0.99, y(0) = 0.01]], arrows = medium);

In this plot, we can observe arrows (vector fields), but in the first example, I cannot to handle it.

Thanks in advance.

When the new Beta application center becomes active and the old one is obsoleted (sigh) many links to the applications centers from here (mapleprimes) will be broken.  Or will the links be directed to the proper location?

Hi,

I tried a simple expressioin using imaginary numbers in MapleFlow,

a:=1 + 2*i

but got the following error:

¨'mn' is not numeric"

does anyone know what is happening?

thanks very much.

In this example, i have a top module A. Inside it, I have module named my_RECORD (which happened to be option object) that I want to return back to caller when they call a proc.

Maple allows me to declare the proc to return my_RECORD. No problem., But when making a local variable inside the proc and using o::my_RECORD it complains  that my_RECORD does not exist. 

The solution is to change o::my_RECORD to o::A:-my_RECORD

My question why it did not complain the same way on the return value on the proc?   for me, they are both semantically the same. One says the proc returns this type, and the other says the local variable is this type. So why had to do A:-my_RECORD on one but not the other? 

Here is an example. Maple 2021.2 on windows 10.

restart;

interface(warnlevel=4);
kernelopts('assertlevel'=2):

3

A:=module()
 #this is the RECORD to return
  local module my_RECORD()
   option object;
   export data::string:="";
  end module;
   
  export do_analysis:=proc()::my_RECORD;   
    local o::my_RECORD; #error here. But this is the same above line above?    
    o:=Object(my_RECORD);
    o:-data:="test";
    return o;        
  end proc;
end module;

_m2642451182336

A:-do_analysis()

Error, (in do_analysis) type `my_RECORD` does not exist

#FIXED BELOW
restart;

A:=module()
    #this is the RECORD to return
    local module my_RECORD()
        option object;
        export data::string:="";
    end module;
   
    export do_analysis:=proc()::my_RECORD;
          local o::A:-my_RECORD;    
          o:=Object(my_RECORD);
          o:-data:="test";
          return o;        
    end proc;
end module;

_m2642339719872

A:-do_analysis()

module my_RECORD () export data::string; option object; end module

 

Download A_no_lib.mw

hi,

I looked at the file mapleflowrc and saw that it lists several palettes that are not visible in the workshheet dock.

Does anyone know if these palettes are available in mapleflow? And if so, how to make them visible in the worksheet dock?

thanks very much in advance.

As maple 1d input:

expr:=(1/2)*a*(b/c)/d;     

As 2 d input : 

This rightside of the equation i like to get in Maple , but how?

answer

I have a very simple task:

convert([a,b],`*`)

the result is of course a*b.  However if I load the Physics package beforehand, that is,

with(Physics)
convert([a,b],`*`)

the followinkg error shows up:

Error, unrecognized conversion: Physics:-`*`

I have read that the Physcs package redefines the mutiplication. This must be the source of the problem.
But how can I proceed. I need to do this task with the Physics package loaded. 
Any help will be appreciated! 

Hello everyone, I'm trying to interpolate a function using the roots of a Chebyshev polynomial as interpolation points, and then compute the absolute error. I want to compute that error via numerical integration, however, Maple is returning the expression of the integration itself. Why is that?

This is the code I'm using:

with(CurveFitting):

u := x -> exp(1/2*x^2 - 1/2):

r := evalf(allvalues(RootOf(ChebyshevT(5, x), x))):
points := Vector(5, i -> r[i]):
u_points := Vector(5, i -> u(points[i])):

P__2 := PolynomialInterpolation(points, u_points, x):

evalf(int(abs(u(x) - P__2), x = -1 .. 1))

This is the result:

I often create diagrams in Maple and export them so I can embed them in a Word Doc.  Lately, when I right-click on the picture so I can select "export," the entire program closes.   It seems to happen more when the picture is in 3D.   Am I doing something wrong?     Thanks.

           David

This is the graph I want but Nb must be equal to Nt. I should get values -diff(theta(eta), eta) for Bi or Nt Nb first?

BiNbNtxx.mw

Dear Users!

Hope everyone is fine here. Let me explain my problem first for this consider
diff(Y(xi), xi) = mu*(1-Y(xi)^2)
Then the derivative of a function U=u(Y(xi)) using chain rule (and expression menstiones as red) is given as,
diff(U, xi) = (diff(diff(Y, xi), Y))*U and (diff(diff(Y, xi), Y))*U = mu*(1-Y(xi)^2)*(diff(U, Y))
Similarly the second-order derivaitve of U=u(Y(xi)) using chain rule (and expression menstiones as red) is given as,
((&DifferentialD;)^(2))/(&DifferentialD; xi^(2))U=(&DifferentialD;)/(&DifferentialD; xi)(mu (1-Y^(2)(xi))*(&DifferentialD;)/(&DifferentialD; Y)U)=((&DifferentialD;)/(&DifferentialD; Y)*(&DifferentialD;)/(&DifferentialD; xi)Y)(mu (1-Y^(2)(xi))*(&DifferentialD;)/(&DifferentialD; Y)U)=(&DifferentialD;)/(&DifferentialD; Y)(mu^(2) (1-Y^(2)(xi))^(2)*(&DifferentialD;)/(&DifferentialD; Y)U)=-2 Y(xi) mu^(2) (1-Y^(2)(xi))*(&DifferentialD;)/(&DifferentialD; Y)U+ mu^(2) (1-Y^(2)(xi))^(2)*((&DifferentialD;)^(2))/(&DifferentialD; Y^(2))U;
In the similar way I want to compute the higher-order (like 5th order) derivaitve of U w.r.t. xi using the chain rule  (and expression menstiones as red) explained in above. Kindly help me soolve my problem

I am waiting for positive response.

Hi there!

I need a function that receives a function of several complex variables f(z), z=z_1,...z_n as an argument and returns its decomposition into its real and imaginary parts as functions of real variables: f(z)=u(x,y)+i*v(x,y).

Here is my Maple code for the case of two complex variables z_1, z_2:

UV:=proc(f, n) #second argument n is a number of variables
  local i, X, Y, XY, w, u, v:
  X:=[seq(x[i], i=1..n)]: # Create lists of real variables x_j, y_j
  Y:=[seq(y[i], i=1..n)]:
  XY:=zip((a,b)->a+I*b, X, Y): # Create a list of x_j + I * y_j
  map(a -> assume(a, real), X): # assume all x_j, y_j are real
  map(a -> assume(a, real), Y):
  w:=f(op(XY)): # substitute x+iy into f(z)
  u:=Re(w):
  v:=Im(w):
  return([u, v]):
end proc:

To call the function, I need to type something like this:
UV((z1,z2) -> exp(z1+z2), 2) 

The trouble I have is when I try calling this function inside another function that receives as arguments n functions of n complex arguments, in other words, it receives two lists, say: Z:=[z_1,...z_n], F:=[f_1,...f_n]. At some point, I need to decompose each f_j into its real and imaginary parts but unfortunately calling UV inside this function neither accepts lists
UV(Z -> f_j, n)
nor it understands something like
UV(op(Z) -> f_j, n) or UV((op(Z)) -> f_j, n).

Maybe my approach to this problem is incorrect from the very beginning, but I don't see any other acceptable ways to do it. Can anybody help me?

5 6 7 8 9 10 11 Last Page 7 of 2084