584 Reputation

7 years, 218 days

plot3d outside of an sphere?...

Maple

how can i plot outside of an sphere? for example x^2+y^2+z^2>1 ? tnx for help

remove "fsolve" residual !...

Maple

i have a function,when using fsolve to solve it, it has two roots. when i substitute it into the main function, it has some residual and it is not exactly 0. how should i remove the residual ? i do not want to use "solve" command and i should use "fsolve" command. tnx in advance

 > restart:
 > f:=3*(2*x-1)^2*(1/2)-1/2;
 (1)
 > ans:=fsolve(f)
 (2)
 > eval(f,x=ans[2])
 (3)
 >
 >
 >

a question on using "subs" command...

Maple

hi, i have an expression "f" and i want to substitute the expression with Square root with another namee like phi, how should i do that? i should not use solve commands since the expression is more complicated and i have just pick part of it. tnx in advance.

 > restart
 > f:=(3*beta[11]^2-4*beta[11]*sigma[11]+6*beta[12]^2-12*beta[12]*sigma[12]+2*sigma[11]^2+6*sigma[12]^2)*(1/sqrt(6*beta[11]^2-8*beta[11]*sigma[11]+12*beta[12]^2-24*beta[12]*sigma[12]+4*sigma[11]^2+12*sigma[12]^2))*(1/omega^2);
 (1)
 > subs(sqrt(6*beta[11]^2-8*beta[11]*sigma[11]+12*beta[12]^2-24*beta[12]*sigma[12]+4*sigma[11]^2+12*sigma[12]^2)=phi,f);
 (2)
 > factor(simplify(f,{sqrt(6*beta[11]^2-8*beta[11]*sigma[11]+12*beta[12]^2-24*beta[12]*sigma[12]+4*sigma[11]^2+12*sigma[12]^2) = phi}));
 > simplify(algsubs(sqrt(6*beta[11]^2-8*beta[11]*sigma[11]+12*beta[12]^2-24*beta[12]*sigma[12]+4*sigma[11]^2+12*sigma[12]^2)=phi,  f))
 > # i want sth like this :
 (3)

a question about using maple engine on m...

Maple

hi everyone

I am trying to call the maple function fsolve in the matlab. I have used maple('fsolve(x^2-4)'). It worked.Now in the matlab code I have defined another variable. let us say a = 10.  Now I am trying to call the fsolve as follows.

a=10;

maple('fsolve(a*x^2-1)')

I ended up with the following error :

Error, (in fsolve) number of equations, 1, does not match number of variables,

could any body help? tnx

a question on output of dsolve...

Maple

i have system of ode, which has three unkonwn function,x(t),y(t),z(t), and i need differentiation of theses function with respect to " t " , how can i use numeric solution to have these parameters? tnx for help in advance

 > restart;
 > wl:=0.08:alpha:=0.5:gamma0:=8.82*1e10:mu0:=4*Pi*1e-7:gammA:=gamma0/(1+alpha^2):alphaPrime:=mu0*gammA*alpha: gamma1:=mu0*gammA:m0:=mu0*1e5:num:=[seq](i,i=1e2..1e4):
 > w:=num[1]: dsys:={diff(x(t), t) =alphaPrime*(z(t)^2*wl*cos(w*t)/gamma1+y(t)^2*wl*cos(w*t)/gamma1),diff(y(t),t)=-z(t)*wl*cos(w*t)-alphaPrime*y(t)*wl*cos(w*t)*x(t)/gamma1,diff(z(t),t)=y(t)*wl*cos(w*t)-alphaPrime*z(t)*wl*cos(w*t)*x(t)/gamma1,x(0)=.01,y(0)=1,z(0)=0.1};
 (1)
 >
 > ans:=dsolve(dsys,numeric,output = listprocedure);
 (2)
 > #i want to have d/dt(x(t),d/dt(y(t),d/dt(z(t)
 >
 >
 >
 >
 >
 >
 >
 >
 >
 >