Items tagged with solve solve Tagged Items Feed

hi,

   here are  equations like this

 sol := [abs(r)^2+abs(t)^2 = 1, r*conjugate(t)+t*conjugate(r), abs(r) = abs(t)]

when i solve this equations using command solve,the result  is none. and i used r=x+I*y,t=u+I*v in the equations,

sol:=[u^2+v^2+x^2+y^2 = 1, 2*u*x+2*v*y, sqrt(x^2+y^2) = sqrt(u^2+v^2)]

i still can't get a result.why,can you help me.

thanks.

 

Hello every one,

I had a 3 equations with 3 unknown (X,Y,Z, conjugate(Y),conjugate(Z))

this is the code:

solve( {ao*x + a1*y + conjugate(a1)*conjugate(y)+a2*z+conjugate(a2)*conjugate(z) = 0.5, conjugate(a1)*x + bo*y + conjugate(a2)*conjugate(y)+a1*z = 0, 10*x + 10*y/4 + 10*z = 10}, {x, y, z});

where the coefficients are complex numbers

Is thee any simple way to solve it

thanks

Hi:

i will solve the five nonlinear coupled odes with maple in least time,can evey body help me?

eq1:= -3515.175096*Pi*q[1](T)*q[4](T)-3515.175096*Pi*q[1](T)*q[5](T)-2650.168890*Pi^2*q[3](T)*q[1](T)-9.871794877*10^7*q[2](T)*Pi+.5622514683*(diff(q[1](T), T, T))+1.893468706*q[1](T)^3*Pi^4+2.507772708*10^5*q[1](T)*Pi^2=0

eq2:= 496.9066665*q[2](T)*Pi^2-380.5288665*q[4](T)*Pi-62694.31768*Pi*q[1](T)+380.5288665*q[5](T)*Pi+0.3570776400e-3*(diff(q[2](T), T, T))+2.467948718*10^7*q[2](T)=0

eq3:= 2650.168888*q[1](T)^2*Pi^2+7.824250847*10^5*q[3](T)*Pi^2+1.037806000*10^6*q[5](T)*Pi+.5622514682*(diff(q[3](T), T, T))+1.037806000*10^6*q[4](T)*Pi=0

eq4:= 63661.97724-241.8620273*q[1](T)*(diff(q[1](T), T))-6.792272727*10^6*(diff(q[4](T), T))-5191.348749*q[4](T)-5191.348749*q[5](T)+71406.36133*(diff(q[3](T), T))-6.792272727*10^6*(diff(q[5](T), T))=0

eq5:= 70.02817496+2490.500000*(diff(q[5](T), T))-29887.90351*q[4](T)+29887.90351*q[5](T)-2490.500000*(diff(q[4](T), T))-45.34913011*(diff(q[2](T), T))=0

Solve Problems ...

July 17 2014 MSac 15

Hi

I can't solve the problem to have the right solution of

solve({cos(x)!=0,x>=0,x<=2*Pi})

while solve works with

solve(cos(x)!=0)

Any ideas on why this happen?

hi all.

I have wrore the following program for optimization with bernstein and block pulse hybrid functions.

the program have some errors which i can't understand.

Bernestien1.mws

restart:

alias(C=binomial):
with(LinearAlgebra):
macro(LA= LinearAlgebra):


HybrFunc:=proc(N, M,  tj)               # N=Number of subintervals,  M=Number of functions in subintervals
 
local B, n, m;

global b;

for n from 1 to N do
for m from 0 to M-1 do

B := (i,m,t) -> C(m,i)*(1-t)^(m-i)*t^i:

b[n,m]:=unapply(piecewise(t>=(n-1)*tj/N and t<n*tj/N, B(m,2,N*t-(n-1)*tj), 0), t):
 od:od:


Array(1..N, 0..M-1, (n,m)->b[n,m](t)):

#convert(%,vector);
end proc:

HybrFunc(3, 3, 1);




                                       # End Of Definition
 
g2(t):=t;            #*exp(t-1):                      # Any other function can be replaced here
    

g1(t):=add(add(c[n,m]*b[n,m](t), m=0..2), n=1..3);
Optimization[Minimize](sqrt(int((g2(t)-g1(t))^2, t=0.. 1)));
assign(op(%[2]));
plot([g2(t),g1(t)], t=0..1, 0..5, color=[blue,red],thickness=[1,3],discont, scaling=constrained);

Array(1 .. 3, 0 .. 2, {(1, 0) = piecewise(0 <= t and t < 1/3, (1-3*t)^2, 0), (1, 1) = piecewise(0 <= t and t < 1/3, (6*(1-3*t))*t, 0), (1, 2) = piecewise(0 <= t and t < 1/3, 9*t^2, 0), (2, 0) = piecewise(1/3 <= t and t < 2/3, (2-3*t)^2, 0), (2, 1) = piecewise(1/3 <= t and t < 2/3, (2*(2-3*t))*(3*t-1), 0), (2, 2) = piecewise(1/3 <= t and t < 2/3, (3*t-1)^2, 0), (3, 0) = piecewise(2/3 <= t and t < 1, (3-3*t)^2, 0), (3, 1) = piecewise(2/3 <= t and t < 1, (2*(3-3*t))*(3*t-2), 0), (3, 2) = piecewise(2/3 <= t and t < 1, (3*t-2)^2, 0)}, datatype = anything, storage = rectangular, order = Fortran_order)

g2(t) := t

"g1(t):=c[1,0] ({[[(1-3 t)^2,0<=t and t<1/3],[0,otherwise]])+c[1,1] ({[[6 (1-3 t) t,0<=t and t<1/3],[0,otherwise]])+c[1,2] ({[[9 t^2,0<=t and t<1/3],[0,otherwise]])+c[2,0] ({[[(2-3 t)^2,1/3<=t and t<2/3],[0,otherwise]])+c[2,1] ({[[2 (2-3 t) (3 t-1),1/3<=t and t<2/3],[0,otherwise]])+c[2,2] ({[[(3 t-1)^2,1/3<=t and t<2/3],[0,otherwise]])+c[3,0] ({[[(3-3 t)^2,2/3<=t and t<1],[0,otherwise]])+c[3,1] ({[[2 (3-3 t) (3 t-2),2/3<=t and t<1],[0,otherwise]])+c[3,2] ({[[(3 t-2)^2,2/3<=t and t<1],[0,otherwise]])"

Error, (in Optimization:-NLPSolve) complex value encountered

Error, invalid left hand side in assignment

(1)



Download Bernestien1.mws

 I'll be so grateful if any one can help me.

Mahmood   Dadkhah

Ph.D Candidate

Applied Mathematics Department

Hi,


Is it possible to solve linear matrix inequality in Maple?
For example, using Matlab and yalmip we can easily
solve Lyapunov equation
  
    A'P + P * A <0, P> 0

Is it possible to solve this equation in the Maple?


Regards,

 

Is it possible to solve piecewise differential equations directly instead of separating the pieces and solving them separately.

like for example if i have a two dimensional function f(t,x) whose dynamics is as follows:

dynamics:= piecewise((t,x) in D1, pde1, pde2); where D1 is some region in (t,x)-plane

now is it possible to solve this system with one pde call numerically?

pde(dynamics, boundary conditions, numeric); doesnot work

This integral is defined as

Where

 

Now, How can I solve this integral?

tnx for your help.

 

 

The answer should be around 15.7, i.e., function h is maximized at around x=15.7, I don't know why my computer/maple is having a hard time with it.

f := proc (a, b, k) options operator, arrow; (sum(exp(-x)*x^m/(m!), m = a .. b))^k end proc;


h := f(0,0,82)*f(1,3,49)*f(4,6,47)*f(7,10,47)*f(11,15,57)*f(16,20,40)*f(21,25,38)*f(26,35,52)*(1-f(0,35,1))^91;


fsolve(diff(h,x),x);

 

thanks in advance!

Hi all

 

I am having a very complicated equation that has the form of 

x*y^2/(x+1)+x*(1/(x-2y)^2)=0

 

Of course, the actual equation is more complicate than above. It is just an example. I want to solve the equation in terms of x. And I know that both x and y are real, and they are positive (greater than 0). My question is, how should I specify this when solving the equation?

 

 

PS: I try to run the program to the solve the equation (without specifying that they are real and positive), and at the output, it gave me something like:

"RootOf(y^2+2y+.......)".   What is that "RootOf" means? Square-root or what?

Hi guys,

im trying to solve the linear equation system:

mysol := solve({J*a = m*l*(-c*ct^2*sf-c*sf*st^2+cf*d*st^2+d*sf*st^2)+m*g*l*st, cx*ux = cMx*xd+M*c+m*l*(-cp*pd^2*st-cp*st*td^2-2*ct*pd*sp*td+a*cp*ct-b*sp*st), cy*uy = cMy*yd+M*d+m*l*(2*cp*ct*pd*td-pd^2*sp*st-sp*st*td^2+a*ct*sp+b*cp*st), (-l^2*m*st^2+J)*b = -ml(c*cf*ct+ct*d*sf)}, {a, b, c, d}) :

Then, assigning the solutions:

assign(mysol):

Then, eliminating the RootOf's for variable a:

a_explicit := allvalues(a):

Unfortunately, a_explicit still contains RootOf's. How can I avoid this?

Thanks,

Martin

 

Hello Maple-Primers!

I am trying to evaluate a system at many different points.  I would like to include an interpolation function in this system, but have thusfar been unsuccessful.

Usually, I solve a system symbolically by using eliminate and unapply:

eq[1] := A = M^3;
eq[2] := C = A*2;
eq[3] := D = N+3;
eq[4] := B = piecewise(A = 0, 0,C);
eq[5] := E = B*D;
elimsol:=eliminate(convert(eq,list),[A,B,C,D,E])[1];

unappsol:=unapply(elimsol,[N,M]);

unappsol(1,2);
{A = 8, B = 16, C = 16, D = 4, E = 64} <--- great!

Now, I want to include an interpolation function in the system of equations.  They look like this (see worksheet for actual interpolation function):

B_interp := (W,T) -> CurveFitting:-ArrayInterpolation([FC_Map_W,FC_Map_T],FC_Map,Array(1 .. 1, 1 .. 1, 1 .. 2, [[[W, T]]]),method=linear);

eq[5] := E = B_interp(N,M);

Error, (in CurveFitting:-ArrayInterpolation) invalid input: coordinates of xvalues must be of type numeric <-- bad!

Anyone have any ideas?  I've tried to use polynomials, but I can't seem to get a fit close enough for my purposes.

Maple_2D_Interpolate_FC.mw

solve([x + 3*y + 5*z = 0,
7*x + 9*y + 11*z = 0,
13*x + 15*y + 17*z = 0],[x,y]);

 

Hello,

       How long can I expect Maple17 to take to algebraically solve a system of 14 nonlinear equations that has approximately 40% nonlinearity in its terms? I am running it on the machine right now, but have no idea what to expect. As mentioned before, I'm new to Maple...

Here is my code:

restart; eq1 := A*z-B*a*z-V*a*q-W*(b+d)*a = 0; eq2 := W*(b+d)*a-V*b*q-(F*G+B+D)*b*z = 0; eq3 := V*a*q-W*c*(b+d)-(B+C+E)*c*z = 0; eq4 := V*b*q+W*(b+d)*c-(B+C+D+F)*d*z = 0; eq5 := G*F*b*z-V*q*e-(B+H)*e*z = 0; eq6 := H*e*z-V*q*f-(B+S)*f*z = 0; eq7 := S*f*z-V*q*g-B*g*z = 0; eq8 := V*q*g+S*s*z-(B+C+E)*h*z = 0; eq9 := F*d*z+V*q*e-(B+C+H+T)*t*z = 0; eq10 := H*t*z+V*q*f-(U+B+C+2*S)*s*z = 0; eq11 := T*t*z-(B+H+Y)*u*z = 0; eq12 := U*s*z-(B+S)*v*z+H*u*z-Y*H*v*z/(H+S) = 0; eq13 := g-c-d-t-s-h = 0; eq14 := z-a-b-c-d-e-f-g-h-s-t-u-v = 0; soln := solve({eq1, eq10, eq11, eq12, eq13, eq14, eq2, eq3, eq4, eq5, eq6, eq7, eq8, eq9}, {a, b, c, d, e, f, g, h, q, s, t, u, v, z});

Thanks.

 

 

Hello,

       I am new to this forum. I have typed the follwing code in Maple17:

restart; eq1 := A-B*a-V*a*q/z-W*(b+d)*a/z = 0; eq2 := W*(b+d)*a/z-V*b*q/z-(F*G+B+D)*b = 0; eq3 := V*a*q/z-W*c(b+d)/z-(B+C+E)*c = 0; eq4 := V*b*q/z+W*(b+d)*c/z-(B+C+D+F)*d = 0; eq5 := G*F*b-V*q*e/z-(B+H)*e = 0; eq6 := H*e-V*q*f/z-(B+S)*f = 0; eq7 := S*f-V*q*g/z-B*g = 0; eq8 := V*q*g/z+S*s-(B+C+E)*h = 0; eq9 := F*d+V*q*e/z-(B+C+H+T)*t = 0; eq10 := H*t+V*q*f/z-(U+B+C+2*S)*s = 0; eq11 := T*t+W*(b+d)*x/z-(B+H+Y)*u = 0; eq12 := U*s-(B+S)*v+H*u-Y*H*v/(H+S) = 0; eq13 := g-c-d-t-s-h = 0; eq14 := z-a-b-c-d-e-f-g-h-s-t-u-v = 0; soln := solve({eq1, eq10, eq11, eq12, eq13, eq14, eq2, eq3, eq4, eq5, eq6, eq7, eq8, eq9}, {a, b, c, d, e, f, g, h, q, s, t, u, v, z});

 

This is to symbolically solve a nonlinear system of (14) equations. But when I press Enter, it just returns the message "Ready". Shouldn't it say "Evaluating"?

I don't see anything syntactically wrong with my code...

1 2 3 4 5 6 7 Last Page 1 of 32