Maple 2016 Questions and Posts

These are Posts and Questions associated with the product, Maple 2016

I have written the following attached code to use Euler explicit method to solve the following IVP

diff(y(x), x) = 2*(1+x)-y(x), y(2) = 5
With Exact solution  y(x) = 2*x+exp(-x)/exp(-2)

However, I found out that my exact results are not correct while the numerical results are okay. What have I done wrong in the code? Can someone modify the code?

Thank you and kind regards.

Hi all, we know Maple provided discrim method to find discriminant of a polynomial 

I want to write a similar method with independent variable is ,... my code is below

Some examples

Maple already similar method? If not have, we can improve performance it?

Thank you very much.

 

Hi,

I have a random variable that follows Uniform(1,4). Now I have a function which is of the following type:

g := a*alpha+b*t/alpha+exp(alpha)

where,

A := RandomVariable(Uniform(c, d));
                 RandomVariable(Uniform(c, d))
f := proc (alpha) options operator, arrow; PDF(A, alpha) end proc;
alpha -> PDF(A, alpha)
#Defining expectation fuction
E := proc (alpha) options operator, arrow; int(alpha*f(alpha), alpha = c .. d) end proc;
alpha -> int(alpha f(alpha), alpha = c .. d)
#g is a function of random variable α, where a and b are parameter

 

now I want to find the expectation of g and the first derivative of expectation of g,

E(g)

diff(E(g), t)

 

I understand the way I have defined E(alpha) is improper. But please understand my intent and help! here is the maple file also doubt_1.mw

Dear all,

Please I want only 8 points to show on this curve, how do I specify it?

plot(ln(1+sin(Pi*x)), x = 0 .. 1, legend = numerical, style = point, symbol = box, color = blue, symbolsize = 15, numpoints = 8);

Thank you all and kind regards.

Please do keep safe amidst this global pandemic.

In my worksheet today my intention was to compare the least squares linear regression for three datasets as indicated, but when I right click on the output as seen in the bottom line to select the plot type, all options state there to be independant variables K[0] and K[1], where as the output displays only the variable K as I intended, which part of my code is creating this confusion for maple?

 

 

 

Worksheet Specific Investigation Content

 

S[0] := proc (N, K) options operator, arrow; map(simplify, {seq(seq(seq(piecewise((a^`ϕ`(b))^(1/(c+1))-floor((a^`ϕ`(b))^(1/(c+1))) = 0, [a, b, c], NULL), a = 1 .. N), b = 1 .. N), c = 1 .. K)}, 'radical') end proc

T := proc (N, K) options operator, arrow; {seq(seq(seq([a, b, c], a = 1 .. N), b = 1 .. N), c = 1 .. K)} end proc:

S[1] := proc (N, K) options operator, arrow; `minus`(T(N, K), S[0](N, K)) end proc:

CardRatio := proc (N, K) options operator, arrow; nops(S[0](N, K))/nops(S[1](N, K)) end proc:

{CurveFitting[LeastSquares]([seq([k, CardRatio(2, k)], k = 1 .. 10)], K), CurveFitting[LeastSquares]([seq([k, CardRatio(3, k)], k = 1 .. 10)], K), CurveFitting[LeastSquares]([seq([k, CardRatio(4, k)], k = 1 .. 10)], K)}

{1, 44268857/45401356-(532409481/9988298320)*K, 24308311919/13309971675-(135902619982/773879781675)*K}

(1.1)

``

 

 

 

 

Download ask_maple.mw

 

 

Hi,

I am writing the following code and MAPLE is giving me operator error. Please help (file: doubt_6.mw)

d2:=100000000

for m in set_m do
    for n in set_n do
        SOL1 := fsolve({ODE11, ODE12}, {N, t__2});
        N1:=eval(N,SOL1);
        t_2_1 :=eval(t__2,SOL1);
        T_1:= eval(T, [lambda = 3, a = 300, b = .15, c = .25, A__m = 300, A__d = 150, A__r = 50,C__m = 4, P__m = 8, P__d = 10, 
        P__r = 12, theta__m = .15, theta__d = .12, theta__r = 0.5e-1, h__m = .2, h__d = .3, h__r = .5, i__m = .1, i__d = .1, 
        i__r = .1, i__om = .1, i__OD = .15, i__c = .3, i__e = .2, M = 2, alpha = 0.2e-1, t__2 = t_2_1]):
        t_31:= T_1 /m ;
        t_41:= T_1 /(m*n) ;
        if (N1<=t_41 and 2>=t_31) then
            d1:= eval(TCS__1, [lambda = 3, a = 300, b = .15, c = .25, A__m = 300, A__d = 150, A__r = 50, C__m = 4, P__m = 8, 
            P__d = 10, P__r = 12, theta__m = .15, theta__d = .12, theta__r = 0.5e-1, h__m = .2, h__d = .3, h__r = .5, i__m = .1, 
            i__d = .1, i__r = .1, i__om = .1, i__OD = .15, i__c = .3, i__e = .2, M = 2, alpha = 0.2e-1, t__2=t_2_1, N=N1]):
            if (d1<= d2) then
                d2:= d1;
                print("Value is updated",d2,N1,t_2_1,"for",m,n)
            end if
        end if    
        print(N1,t_2_1,t_31,t_41,d1,m,n)
    end do
end do

 

Thanks in advance

 

[[p__jb = (Typesetting[delayDotProduct](c__a . ((rho*(-1+alpha)*t__a-alpha*t__b)/(t__b*t__a)), t__b, true)*t__a+((c__b+`p__-jb`)*alpha-c__b-t__b-`p__-jb`)*t__a-alpha*t__b*(c__b+`p__-jb`))/((2*alpha-2)*t__a-2*alpha*t__b)]]

hi

I'm working on my thesis,to solve a particular problem,I created a 84*84 matrix in Matlab.

I want to calculate the determinat of that matrix in maple,so from tools>assistance>import date added this matrix in maple.

every thing seems to be ok but when i want to caculate the determinant this error apears :

 Error, (in LinearAlgebra:-Determinant) matrix must be square

does anybody know what is the problem here?

Also sorry for my weak English 

and it's worth mentioning that I'm a beginner in maple programming 

thank you

 

 

doubt5.mw

Hi I want to run the following algorithm in code edit region:

for m in set_m do
    for n in set_n do
      solve for N solving ODE11 and ODE12 simultaneously
      solve for t_2 solving ODE11 and ODE12 simultaneouly
      find t__3 and t__4
      if (N<=t_4 and M>=t_3) then
        d1= TCS__1 using n,m,t__2 and N
          if (d1< d2)
            d2=d1
            print(d2,m,n,N,t_2)
    end do
end do
 

But I am struck for to how to extract N and t__2 from SOL1 in code edit region

SOL1 := fsolve({ODE11, ODE12}, {N, t__2});

Thanks in advance

doubt4.mw

Hi, As shown in the figure(red color). I am not able to understand why Exp(0) is not showing as 1. As evaluating rules of maple says that it evaluates everything till it gets unassigned variables.

Do I am doing something wrong? There is a link to the file. 

Thanks in advance

doubt_3.mw

Hi, I am trying to do a simple think like

od2 := diff(x^3, x)+v+2 = 0

od3 := diff(v^2, v)+x+4 = 0

solve({(1),(2)},{x,v})

 

but with my code,  I am doing the exact same but getting the following error

Error, invalid input: solve expects its 1st argument, eqs, to be of type {`and`, `not`, `or`, algebraic, relation(algebraic), ({list, set})({`and`, `not`, `or`, algebraic, relation(algebraic)})}, but received {[1316.872428*(-0.1500000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+3.000000*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.2250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.2304687500e-6*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.3662109374e-8*t__2^4*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^4*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.5320312500e-4*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-3.000000)*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(int(.2*(.1*t+1)*i__m2(t), t = 0 .. t__2))/N^.98-11.76000000/(N^.98*((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2))+1185.185185*(-0.1953125000e-5*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.4898437500e-3*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.7500000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+6.0000*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-6.0000)*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))/(N^.98*((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2))+6.00*(-75.50000000*N^2.02+45.45000000*N^1.02+306.00*N^0.2e-1)/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)-1.200000000/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)-9.6*(-75.37500000*N^3.02+45.30000000*N^2.02+303.00*N^1.02)/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)] = 0, [-650*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2+65843.62140*N^0.2e-1*(-0.6750000000e-3*t__2^2-0.1350000000e-1*t__2+0.7500000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`-0.9000000000e-1-0.1500000000e-1*t__2*(0.900e-1*t__2+.90)+3.000000*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.2250000000e-1*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.2250000000e-1*t__2*(0.900e-1*t__2+.90)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.2250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.6914062500e-6*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.6914062500e-6*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(0.900e-1*t__2+.90)+0.2304687500e-6*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.1464843750e-7*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^4*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.1464843750e-7*t__2^4*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(0.900e-1*t__2+.90)-0.3662109374e-8*t__2^4*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^4*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.1064062500e-3*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.1064062500e-3*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(0.900e-1*t__2+.90)+0.5320312500e-4*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)))*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(int(.2*(.1*t+1)*i__m2(t), t = 0 .. t__2))+65843.62140*N^0.2e-1*(-0.1500000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+3.000000*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.2250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.2304687500e-6*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.3662109374e-8*t__2^4*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^4*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.5320312500e-4*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-3.000000)*(-0.5625000000e-3*t__2^2-0.1125000000e-1*t__2+0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`-0.7500000000e-1-0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(int(.2*(.1*t+1)*i__m2(t), t = 0 .. t__2))+13168.72428*N^0.2e-1*(-0.1500000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+3.000000*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.2250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.2304687500e-6*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.3662109374e-8*t__2^4*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^4*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.5320312500e-4*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-3.000000)*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(.1*t__2+1)*i__m2(t__2)+588.0000000*N^0.2e-1*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2+.60*(98765.43210*N^0.2e-1*(-0.5859375000e-5*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.5859375000e-5*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(0.900e-1*t__2+.90)-0.1953125000e-5*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.9796875000e-3*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.9796875000e-3*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))*(0.900e-1*t__2+.90)+0.4898437500e-3*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.7500000000e-1*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.7500000000e-1*t__2*(0.900e-1*t__2+.90)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.7500000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+6.0000*(0.5625000000e-3*t__2^2+0.1125000000e-1*t__2-0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+0.7500000000e-1+0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)))*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+98765.43210*N^0.2e-1*(-0.1953125000e-5*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.4898437500e-3*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.7500000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+6.0000*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-6.0000)*(-0.5625000000e-3*t__2^2-0.1125000000e-1*t__2+0.6250000000e-2*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`-0.7500000000e-1-0.1250000000e-1*t__2*(0.900e-1*t__2+.90))*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+i__m2(t__2))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)-.60*(98765.43210*N^0.2e-1*(-0.1953125000e-5*t__2^3*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^3*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+0.4898437500e-3*t__2^2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)^2*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-0.7500000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+6.0000*exp(0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))-6.0000)*exp(-0.1250000000e-1*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6))+int(i__m2(t), t = 0 .. t__2))*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2-(0.1500000000e-2*T^2+0.3000000000e-1*T)*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2-6.00*(-25.00000000*N^3.02+22.50000000*N^2.02+300*N^1.02)*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2-.1700000000*T*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2-2.4*(.1000000000*T-.2000000000)*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2-4*(0.1562500000e-3*T^2+0.1250000000e-1*T)*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2-12.0*(0.2500000000e-1*T-.1000000000*N)*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2+9.6*(-18.75000000*N^4.02+15.00000000*N^3.02+150*N^2.02)*(0.3750000000e-2*t__2^2+0.7500000000e-1*t__2-0.4166666667e-1*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+3/2+(1/12)*t__2*(0.900e-1*t__2+.90))/((1/12)*t__2*(0.450e-1*t__2^2+.90*t__2-.50*`#msup(msub(mi("\`t"),mi("2\`")),mn("2"))`+6)+t__2)^2] = 0}

 

Please help

Thanks in advance 

Hi, I am working on a bification diagram and was wondering if there is a way to plot the stable and unstable curves onto one figure.

I have two curves, if the eq1<eq2 I would like to indicate when this happens, with a dashed line.

When eq1>eq3 I would like to indicate this with a soild line.

implicitplot, x[m] vs x[u] with axis[2]=[mode=log] 

r:=0.927: K:=1.8182*10^8:d[v]:=0.0038:d[u]:=2: delta:=1: p[m]:=2.5: M:=10^4: p[e]:=0.4: d[e]:=0.1: d[t]:=5*10^(-9): omega:=2.042: b:=1000: h[e]:=1000:h[u]:=1:h[v]:=10^4:

eq1 := r*d[t]*h[e]*x[u]^3+(r*h[e]*(-K*d[t]+d[t]*h[v]+d[e])+r*p[e]*x[m])*x[u]^2+(r*h[e]*(-K*d[t]*h[v]-K*d[e]+d[e]*h[v])+K*p[e]*(d[u]-r)*x[m])*x[u]-r*K*h[e]*d[e]*h[v];

eq2 := (d[t]*x[u]+d[e])*(2*r*x[u]/K+d[u]*p[e]*x[m]*x[u]/((h[v]+x[u])*(d[t]*x[u]+d[e])*(h[e]+p[e]*x[m]*x[u]/((h[v]+x[u])*(d[t]*x[u]+d[e]))))-r)+d[u]*h[e]*x[u]*(p[e]*h[v]*x[m]/(h[v]+x[u])^2-d[t]*p[e]*x[m]*x[u]/((h[v]+x[u])*(d[t]*x[u]+d[e])))/(h[e]+p[e]*x[m]*x[u]/((h[v]+x[u])*(d[t]*x[u]+d[e])))^2

Hi, am trying to differentiate the following eq w.r.t t2 and N. But in t2 I am getting zero and in wrt N, an Error (non-algebraic expressions cannot be differentiated). But according to the article, I am following expression should come.

I am differentiating following

TCS := proc (N, T, m, n) options operator, arrow; piecewise(M <= t__3 and N <= t__4, TCS__1, M <= t__3 and t__4 < N, TCS__2, t__3 <= M and N <= t__4, TCS__3, `t__3 ` <= M and t__4 < N, TCS__4) end proc

ode5 := diff(proc (N, T, m, n) options operator, arrow; piecewise(M <= t__3 and N <= t__4, TCS__1, M <= t__3 and t__4 < N, TCS__2, t__3 <= M and N <= t__4, TCS__3, `t__3 ` <= M and t__4 < N, TCS__4) end proc, t__2) = 0

ode6 := diff(proc (N, T, m, n) options operator, arrow; piecewise(M <= t__3 and N <= t__4, TCS__1, M <= t__3 and t__4 < N, TCS__2, t__3 <= M and N <= t__4, TCS__3, `t__3 ` <= M and t__4 < N, TCS__4) end proc, N) = 0

Error, non-algebraic expressions cannot be differentiated
 

following are the pre-requisite to use above (also in the attachment doubt_2.mw)

i__m1(t) = ((-c*t^2*theta__m^2+b*t*theta__m^2+2*c*t*theta__m-b*theta__m+theta__m^2-2*c)*exp(theta__m*t)*a*N^alpha*(lambda-1)/theta__m^3-(-b*theta__m+theta__m^2-2*c)*a*N^alpha*(lambda-1)/theta__m^3)*exp(-theta__m*t)

i__m2(t) = (-(-c*t^2*theta__m^2+b*t*theta__m^2+2*c*t*theta__m-b*theta__m+theta__m^2-2*c)*exp(theta__m*t)*a*N^alpha/theta__m^3+(-c*t__2^2*theta__m^2+b*t__2*theta__m^2+2*c*t__2*theta__m-b*theta__m+theta__m^2-2*c)*exp(theta__m*t__2)*a*N^alpha/theta__m^3)*exp(-theta__m*t)

TC__m := A__m/(t__1+t__2)+(int(h__m*(i__m*t+1)*i__m1(t), t = 0 .. t__1))*(int(h__m*(i__m*t+1)*i__m2(t), t = 0 .. t__2))+P__m*I__om*m*(-(1/3)*a*c*N^alpha*M^3+(1/2)*a*b*N^alpha*M^2+a*N^alpha*M)/(t__1+t__2)+C__m*theta__m*(int(i__m1(t), t = 0 .. t__1)+int(i__m2(t), t = 0 .. t__2))/(t__1+t__2)

i__d(t) = (-(-c*t^2*theta__d^2+b*t*theta__d^2+2*c*t*theta__d-b*theta__d+theta__d^2-2*c)*a*N^alpha*exp(theta__d*t)/theta__d^3+(-c*t__3^2*theta__d^2+b*t__3*theta__d^2+2*c*t__3*theta__d-b*theta__d+theta__d^2-2*c)*a*N^alpha*exp(theta__d*t__3)/theta__d^3)*exp(-theta__d*t)

TC__d1 := A__d*m/(t__1+t__2)+m*(int(h__d*(i__d*t+1)*i__d(t), t = 0 .. t__3))/(t__1+t__2)+P__d*I__OD*m*n*(-(1/3)*a*c*N^alpha*N^3+(1/2)*a*b*N^alpha*N^2+a*N^alpha*N)/(t__1+t__2)+P__m*theta__m*m*(int(i__d(t), t = 0 .. t__3))/(t__1+t__2)+P__m*I__c*m*(int(i__d(t), t = M .. t__3))/(t__1+t__2)-P__d*I__e*m*(-(1/3)*a*c*N^alpha*M^3+(1/2)*a*b*N^alpha*M^2+a*N^alpha*M)/(t__1+t__2)

TC__d2 := A__d*m/(t__1+t__2)+m*(int(h__d*(i__d*t+1)*i__d(t), t = 0 .. t__3))/(t__1+t__2)+P__d*I__OD*m*n*(-(1/3)*a*c*N^alpha*N^3+(1/2)*a*b*N^alpha*N^2+a*N^alpha*N)/(t__1+t__2)+P__m*theta__m*m*(int(i__d(t), t = 0 .. t__3))/(t__1+t__2)-P__d*I__e*m*(-(1/4)*a*c*N^alpha*t__3^4+(1/3)*a*b*N^alpha*t__3^3+(1/2)*a*N^alpha*t__3^2+M-t__3-(1/3)*a*c*N^alpha*t__3^3+(1/2)*a*b*N^alpha*t__3^2+a*N^alpha*t__3)/(t__1+t__2)

i__r(t) = (-(-c*t^2*theta__r^2+b*t*theta__r^2+2*c*t*theta__r-b*theta__r+theta__r^2-2*c)*a*N^alpha*exp(theta__r*t)/theta__r^3+(-c*t__4^2*theta__r^2+b*t__4*theta__r^2+2*c*t__4*theta__r-b*theta__r+theta__r^2-2*c)*a*N^alpha*exp(theta__r*t__4)/theta__r^3)*exp(-theta__r*t)

TC__r1 := A__r*m*n/(t__1+t__2)+m*n*(int(h__r*(i__r*t+1)*i__r(t), t = 0 .. t__4))/(t__1+t__2)+P__d*theta__r*m*n*(int(i__r(t), t = 0 .. t__4))/(t__1+t__2)+P__d*I__c*m*n*(int(i__r(t), t = N .. t__4))/(t__1+t__2)-P__r*I__e*m*n*(-(1/4)*a*c*N^alpha*N^4+(1/3)*a*b*N^alpha*N^3+(1/2)*a*N^alpha*N^2)/(t__1+t__2)

TC__r2 := A__r*m*n/(t__1+t__2)+m*n*(int(h__r*(i__r*t+1)*i__r(t), t = 0 .. t__4))/(t__1+t__2)+P__d*theta__r*m*n*(int(i__r(t), t = 0 .. t__4))/(t__1+t__2)-P__r*I__e*m*n*(-(1/4)*a*c*N^alpha*t__4^4+(1/3)*a*b*N^alpha*t__4^3+(1/2)*a*N^alpha*t__4^2+N-t__4-(1/3)*a*c*N^alpha*t__4^3+(1/2)*a*b*N^alpha*t__4^2+a*N^alpha*t__4)/(t__1+t__2)

TCS__1 := TC__m+TC__d1+TC__r1

TCS__2 := TC__m+TC__d1+TC__r2

TCS__3 := TC__m+TC__d2+TC__r1

TCS__4 := TC__m+TC__d2+TC__r2

 

Thanks in advance.


doubt_1.mw

Hi, I am trying to solve two simultaneous equations (for t1) they are as follows-

eq 1

i__m2(0) = (-(-b*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`+`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2-2*c)*exp(0)*a*N^alpha/`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^3+(-c*t__2^2*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2+b*t__2*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2+2*c*t__2*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`-b*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`+`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2-2*c)*exp(`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`*t__2)*a*N^alpha/`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^3)*exp(0)

eq 2

i__m1(t__1) = ((-c*t__1^2*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2+b*t__1*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2+2*c*t__1*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`-b*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`+`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2-2*c)*exp(`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`*t__1)*a*N^alpha*(lambda-1)/`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^3-(-b*`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`+`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^2-2*c)*a*N^alpha*(lambda-1)/`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`^3)*exp(-`#msub(mi("&theta;",fontstyle = "normal"),mi("m"))`*t__1)

rhs(i__m2(0) = (-(-b*theta__m+theta__m^2-2*c)*exp(0)*a*N^alpha/theta__m^3+(-c*t__2^2*theta__m^2+b*t__2*theta__m^2+2*c*t__2*theta__m-b*theta__m+theta__m^2-2*c)*exp(theta__m*t__2)*a*N^alpha/theta__m^3)*exp(0)) = rhs(i__m1(t__1) = ((-c*t__1^2*theta__m^2+b*t__1*theta__m^2+2*c*t__1*theta__m-b*theta__m+theta__m^2-2*c)*exp(theta__m*t__1)*a*N^alpha*(lambda-1)/theta__m^3-(-b*theta__m+theta__m^2-2*c)*a*N^alpha*(lambda-1)/theta__m^3)*exp(-theta__m*t__1))

solve({-(-b*theta__m+theta__m^2-2*c)*a*N^alpha/theta__m^3+(-c*t__2^2*theta__m^2+b*t__2*theta__m^2+2*c*t__2*theta__m-b*theta__m+theta__m^2-2*c)*exp(theta__m*t__2)*a*N^alpha/theta__m^3 = ((-c*t__1^2*theta__m^2+b*t__1*theta__m^2+2*c*t__1*theta__m-b*theta__m+theta__m^2-2*c)*exp(theta__m*t__1)*a*N^alpha*(lambda-1)/theta__m^3-(-b*theta__m+theta__m^2-2*c)*a*N^alpha*(lambda-1)/theta__m^3)*exp(-theta__m*t__1)}, [t__1]);
Warning, solutions may have been lost
 

Can someone, please help. Thanks in advance.

Dear All.

I hope we are all staying safe.

Please I want to solve Sine Gordon Equation using a numerical method I constructed (non-classical), I need to compare the result of the method with the exact solution to generate the errors. However, since the exact solution has two variables, x, and t, I really don't know how to accommodate the two in my coding.

Can someone be of help in this regard?

Thank you and kind regards

 


Download Discretization_of_Sine_Gordon_Equation.mw

Download Sine_Gordon_Implementation_Trial.mw

 

4 5 6 7 8 9 10 Last Page 6 of 60