## How to sort expressions numerically...

Hi,

I am looking to convert two expressions into to one, however, their arguments are supposed to be numerically in order:

fsolve(2*x^5-x^4-0.5*x^3+3*x^2-0.5)
-1., -0.415862444399209580898770761551,0.425609408597783496007437773936

fsolve(x^2-1)
-1.00000000000000000000000000000, 1.

For my procedure, I need them in order, namely

-1,-1, -0.415862444399209580898770761551,0.425609408597783496007437773936,1

Is it possible to do this with expressions without having to convert them to a list? Since my following code expects expressions, and not lists, I wouldn't like to change the whole program around it.

## Difficult in getting solution...

In the present problem

I am trying to obtain the numerical solution and graphs for the f' theta1 and theta2 curves vs eta profile

please anyone help me to obtain the solution

i have attached my worksheet below

Thank you for your precious time.

## Animating a cone...

Hello

I am currently working on a visual proof that cutting a cone with a plane, can give you a mathematically correct ellipse.
Therefore i want to animate a cone, using the "cone" command, where you can set the origin, radius and height. I was wondering if it is possible to, using the animate command, make an animation with a cone, either chaning radius of base or height. I have tried various combinations of different commands, but have not had any success. I hope you can help me out!

- Oscar

## Profiling with sub-procedures...

Hi!

Is there a way to use the profiling function for procedures within a procedure? I have this code as an example:

Test:=proc(a,b)::real;

local c;Ergebnis;

Test2:= proc(d,e) #Prozedur zum Schreiben der Ausgaben

f:=d+e;
g:=f*d;
5+3;
3/0;
end proc:
c:=a+b;
Ergebnis:=Test2(a,c)
end proc:

infolevel[Test]:= 2:
CodeTools:-Profiling:-Profile(Test):
Test(3,4);
CodeTools:-Profiling:-PrintProfiles(Test);

just profiling Test2, the subprocedure, doesn't do anything. Obviously, in this example, the division by zero is the problem, however, I am interested in a general solution to detect more complicated problems within a sub-procedure. Is there a way to also profile it, and thus see where the computation stops?

## ExportingÂ Maple 3d graphics toÂ Latex with high qua...

I want to export Maple 3d graphics to Latex with high quality. ( MAPLE 2020.1)

I export the 3d graphics to a .jpeg or.png file, but the quality of graphics is very poor. So, I want to prefer Encapsulated PostScript files (.eps) format.

I select the figure, right-click it and choose "Export as". and  I save the figure as  .eps file. No problem I get a file. But when I add the eps figure to Latex, I live some problems:

MY Example Code:

```restart:
with(plots):

P1:=plot3d(x*y, colorscheme=scheme1,style=surfacecontour ):
P2:=plot3d(x*y,colorscheme=scheme1,style=point,symbol=asterisk):
final_plot:=display({P1,P2}); #I want to export this figure to .eps
```

PROBLEMS which I live:

• Sometimes I get the result as follows:

• Sometimes compiling takes too long time in latex, I don't get any results or get an error. (I tried on the all of TexStudio or TexMaker or overleaf)

I read the previous post on this site and applied the suggestions, but I still live the same problem.

P.S.

I can add Maple 2d graphics to LATEX without any problem.

Any help would be appreciated.

## How to subs/ collect expressions ?...

Hi everyone,

I have two expressions given by:

A := -sqrt(m(p[1](t))/m(q[1](t)))*p[2](t) - l[1]*q[1](t) + l[1]*p[1](t) + q[2](t);

B := -(-sqrt(m(p[1](t))/m(q[1](t))^3)*C(p[1](t))*m(q[1](t))^(3/2)*p[2](t)^2*m(p[1](t)) + C(p[1](t))*p[2](t)^3*m(q[1](t))^(3/2)*sqrt(m(p[1](t))/m(q[1](t))) - l[1]*p[2](t)^2*C(p[1](t))*(p[1](t) - q[1](t))*m(q[1](t))^(3/2) - sqrt(m(q[1](t)))*l[2]*(p[1](t) - q[1](t))*m(p[1](t))^(3/2) + m(p[1](t))*l[1]*p[2](t)*C(p[1](t))*(p[1](t) - q[1](t))*sqrt(m(q[1](t))) - C(q[1](t))*q[2](t)^2*sqrt(m(p[1](t)))*m(q[1](t))*(q[2](t) - 1))/(sqrt(m(p[1](t)))*m(q[1](t))^(3/2));

I would like to rewrite these two expressions according to a and b (replace in A and B each: q[1](t) - p[1](t)  by a and   sqrt(m(q[1](t)))*q[2](t) - sqrt(m(p[1](t)))*p[2](t) by ), such that :

a := q[1](t) - p[1](t);
b := sqrt(m(q[1](t)))*q[2](t) - sqrt(m(p[1](t)))*p[2](t);

I used subs and collect but doesn’t work.

Could you help me please ?

I would like to thank you in advance.

Best regards,

## The gridlines in 3dplots...

I want to write a procedure for adding gridlines to 3dplots of any function f on ([x_min,x_max]x[y_min,y_max])

```restart:
with(plots):
grids:=proc(f,x_min,x_max,y_min,y_max)
local z_min,z_max,plot_f,xz,yz,xy;
uses plots;
z_min:=0:
z_max:=10:
plot_f:=plot3d(f,x=x_min..x_max,y=y_min..y_max);
xz:=plot3d([x,y_min,z],x=x_min..x_max,z=z_min..z_max,style=line,color=blue,thickness=0,grid=[6,6]);
yz:=plot3d([x_min,y,z],y=y_min..y_max,z=z_min..z_max,style=line,color=blue,thickness=0,grid=[4,6]);
xy:=plot3d([x,y,z_min],x=x_min..x_max,y=y_min..y_max,style=line,color=blue,thickness=0,grid=[4,4]);
return
display(plot_f,xz,yz,xy,lightmodel=none,tickmarks=[3,3,6],labels=[x,y,"f(x,y)"],labeldirections=[horizontal,horizontal,vertical],axes=frame);
end proc:

#EXAMPLE
f:=x^2-y:
x_min:=-1:
x_max:=3:
y_min:=-2:
y_max:=1:
grids(f,-1,3,-2,-1);

```