Maple 18 Questions and Posts

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

Dear all

Can we use maple to compute integral using the residual theorem

Compute_integral.mw

 

We can consider the contour a circle that contains one pole (Ipi/2)

Many thanks

 

Dear maple users,
Greetings.
I am solving an ode problem with an analytical solution.
programming running properly, but my plot not exact with the already existing article plot. 
how to get the exact plot.

Thanking you.

Code:JVB.mw
 

restart

N := 3;

3

 

1

(1)

dsolve(diff(f(x), `$`(x, 3)));

f(x) = (1/2)*_C1*x^2+_C2*x+_C3

(2)

Rf := 2*(diff(f[m-1](x), x, x, x))-(2*mh*mh)*(diff(f[m-1](x), x))+sum(f[m-1-n](x)*(diff(f[n](x), x)), n = 0 .. m-1)-bet*(sum(sum(2*f[m-1-n](x)*(diff(f[n-t](x), x))*(diff(f[t](x), x, x))+f[m-1-n](x)*f[n-t](x)*(diff(f[t](x), x, x, x))+x*(diff(f[m-1-n](x), x))*(diff(f[n-t](x), x))*(diff(f[t](x), x, x)), t = 0 .. n), n = 0 .. m-1));

2*(diff(diff(diff(f[m-1](x), x), x), x))-2*(diff(f[m-1](x), x))+sum(f[m-1-n](x)*(diff(f[n](x), x)), n = 0 .. m-1)-.2*(sum(sum(2*f[m-1-n](x)*(diff(f[n-t](x), x))*(diff(diff(f[t](x), x), x))+f[m-1-n](x)*f[n-t](x)*(diff(diff(diff(f[t](x), x), x), x))+x*(diff(f[m-1-n](x), x))*(diff(f[n-t](x), x))*(diff(diff(f[t](x), x), x)), t = 0 .. n), n = 0 .. m-1))

(3)

dsolve(diff(f[m](x), x, x, x)-CHI[m]*(diff(f[m-1](x), x, x, x)) = h*H*Rf, f[m](x));

f[m](x) = Int(Int(Int(CHI[m]*(diff(diff(diff(f[m-1](x), x), x), x))+2*h*(diff(diff(diff(f[m-1](x), x), x), x))-2*h*(diff(f[m-1](x), x))+h*(sum(f[m-1-n](x)*(diff(f[n](x), x)), n = 0 .. m-1))-(1/5)*h*(sum(sum(2*f[m-1-n](x)*(diff(f[n-t](x), x))*(diff(diff(f[t](x), x), x))+f[m-1-n](x)*f[n-t](x)*(diff(diff(diff(f[t](x), x), x), x))+x*(diff(f[m-1-n](x), x))*(diff(f[n-t](x), x))*(diff(diff(f[t](x), x), x)), t = 0 .. n), n = 0 .. m-1)), x), x)+_C1*x, x)+_C2*x+_C3

(4)

f[0](x) := 1-exp(x);

1-exp(x)

(5)

for m to N do CHI[m] := `if`(m > 1, 1, 0); f[m](x) := int(int(int(2*CHI[m]*(diff(f[m-1](x), x, x, x))-(2*h*H*mh*mh)*(diff(f[m-1](x), x))+h*H*(sum(f[m-1-n](x)*(diff(f[n](x), x)), n = 0 .. m-1)), x)-h*H*(sum(sum(2*f[m-1-n](x)*(diff(f[n-t](x), x))*(diff(f[t](x), x, x))+f[m-1-n](x)*f[n-t](x)*(diff(f[t](x), x, x, x))+x*(diff(f[m-1-n](x), x))*(diff(f[n-t](x), x))*(diff(f[t](x), x, x)), t = 0 .. n), n = 0 .. m-1))*bet, x)+_C1*x, x)+_C2*x+_C3; s1 := evalf(subs(x = 0, f[m](x))) = 0; s2 := evalf(subs(x = 0, diff(f[m](x), x))) = 0; s3 := evalf(subs(x = 1, f[m](x))) = 0; s := {s1, s2, s3}; f[m](x) := simplify(subs(solve(s, {_C1, _C2, _C3}), f[m](x))) end do:

f(x) := sum(f[l](x), l = 0 .. N);

1-0.7644444444e-1*exp(5.*x)*h^2*x-0.1333333333e-1*x^2*exp(5.*x)*h^2-2.675700596*exp(2.*x)*h^2*x-0.5876096022e-1*exp(6.*x)*h^3*x-0.9282030175e-2*x^2*exp(6.*x)*h^3+.9962792493*exp(3.*x)*h^3*x+.1647896790*exp(5.*x)*h^3*x+0.2066962962e-1*x^2*exp(5.*x)*h^3+3.357118680*exp(2.*x)*h^3*x-.3264340965*exp(4.*x)*h^3*x+0.3999999998e-1*exp(2.*x)*ln(exp(x))*h^2+58.61348006*h^3+1.023148148*h^2*x^3+0.1364197531e-1*ln(exp(x))*h^3*x^3-0.8954734530e-1*exp(2.*x)*h^3*x^4-.1353159884*x^3*exp(4.*x)*h^3+.7542645986*exp(3.*x)*h^3*x^2-0.2830138323e-1*x^3*h^3*exp(3.*x)-0.6455420536e-1*exp(x)*h^3*ln(exp(x))*x+0.4775858416e-1*exp(x)*h^3*ln(exp(x))*x^2+0.8888888887e-3*exp(x)*h^3*ln(exp(x))^2+8.400000000*h*exp(x)-exp(x)-0.6666666666e-1*h*ln(exp(x))+.1416666666*exp(4.*x)*h^2*x-.4790123458*exp(3.*x)*h^2*x+.1333333333*exp(3.*x)*h*x+.3791666665*exp(4.*x)*h^2-1.340020575*exp(3.*x)*h^2+.3111111109*exp(3.*x)*h+5.570191338*h^2*exp(2.*x)-.4500000000*h*exp(2.*x)-0.9874869443e-1*exp(6.*x)*h^3+.4125877323*exp(3.*x)*h^3-4.984787877*h^3*exp(2.*x)-.8010958741*exp(4.*x)*h^3+.3215641638*exp(5.*x)*h^3-5.930474628*h^2*x+36.04284024*exp(x)*h^3*x+8.324321524*x^2*h^2-.5362260993*h^3*x^3-6.207072379*exp(x)*x^2*h^3+1.664189246*exp(x)*h^3*x^3-8.237962963*h+.1200000000*exp(x)*h^2*ln(exp(x))+0.2222222222e-1*exp(3*x)*h*x+24.00299428*h^3*x-2.098561083*x^2*h^3-53.48457977*h^3*exp(x)+0.9949705035e-2*ln(exp(x))*h^3*x^4-0.7308641971e-2*ln(exp(x))*exp(4.*x)*h^3+0.8984910834e-2*ln(exp(x))*exp(3.*x)*h^3-0.3741666666e-1*ln(exp(x))*h^3*exp(2.*x)-.1188740741*exp(5.*x)*h^2-12.53662834*x^2*h+25.90916526*h^2*exp(x)-30.39962862*h^2-0.7499999999e-1*h*exp(2*x)+0.5185185185e-1*exp(3*x)*h+5.372840718*exp(x)*x^2*h^2-25.09181716*exp(x)*h^2*x+0.8976305409e-1*h^3*x^5+0.2158026099e-1*exp(7.*x)*h^3+0.8606919260e-1*h^3*x^4+0.5079365079e-3*x^3*exp(7.*x)*h^3-.3215468487*x^2*exp(4.*x)*h^3+0.1762236380e-1*exp(7.*x)*h^3*x+0.5048727639e-2*exp(7.*x)*x^2*h^3-3.116709690*exp(2.*x)*x^2*h^3+.1066289908*exp(2.*x)*h^3*x^3-8.527777777*h*x-0.2814814814e-2*ln(exp(x))*exp(4.*x)*h^3*x-0.1053497943e-2*ln(exp(x))*exp(3.*x)*h^3*x+0.4848332783e-1*h^3*x^6+.7462278773*h^2*x^4+.5519508187*exp(x)*h^3*x^4+0.9367631194e-1*exp(x)*h^3*ln(exp(x))+3.581893812*exp(2.*x)*x^2*h^2

 

 

NULL


 

Download JVB.mw

 

Analytical solution approach:

 

 

 

 

Dear all

I hope to find the supremum of the sequence of the function using maple 18, but when I run the code there is no results

maximize.mw

Many thanks

 

 

Hi, I have the following problem:

I want to plot the cone given by 1/16*(3x^2+10xz+3z^2-16y^2) and x>=0, z>=0. I tried it with

implicitplot3d([1/16*(3*x^2+10*x*z-16*y^2+3*z^2), x >= 0, z >= 0], x = -5 .. 15, y = -15 .. 15, z = -5 .. 15, grid = [30, 30, 30], style = surface);

But the result is one surface for each inequaility and not the cone.

If i restrict the range of x and z to be 0..15 and dismiss the additonal inequalities, a big part of the cone surface is missing somehow:

Does anybody know how to fix this? Do I have to use another plotcommand?

Thanks for your help!

;

= 2*1/10);
                               1
                               -
                               5
= -1;
                               -1

= 10;
                               10
= -25;
                              -25

C= 1;
                               1

= (1/12*sqrt6/sqrtbeta*lambda*mu);
                       1     (1/2)  (1/2)
                      --- I 6      2     
                       24                
= alpha/((10*sqrt-lambda*mu)*beta);
                             1  (1/2)
                           - - 5     
                             4       
A0]= (1/2*alpha/((10*sqrt-lambda*mu)*(1/12*beta*sqrt6/sqrtbeta*lambda*mu)));
                    1    (1/2)  (1/2)  (1/2)
                   -- I 5      6      2     
                    4                       
A1]= -(1/10*alpha/((1/12*beta*mu*sqrt6/sqrtbeta*lambda*mu));
                        1    (1/2)  (1/2)
                       -- I 6      2     
                        2                
A[2] := -(12*((112)*sqrt(6)/sqrt(beta*lambda*mu)))*lambda^2*alpha/(10*sqrt(-lambda*mu));
                    1     (1/2)  (1/2)  (1/2)
                   --- I 6      2      5     
                    20                       
H := ln(sqrt(lambda/(-mu))*tanh(sqrt(-lambda*mu)*(xi+C)));
              /1/2)     /1  (1/2         \\
              ln|- 5      tanh|- 5      ( 1)||
                \5            \5                //
xi := k*x-t*w;
                1     (1/2)  (1/2)     1    (1/2)
               --- I 6      2      x + t    
        2               4         
u[0] := A[0]+A[1]*exp(-H)+A[2]*exp(-H)*exp(-H);
  1    (1/2)  (1/2)  (1/2)
 -- I 5      6      2     
  4                       

                     1    (1/2)  (1/2)  (1/2)                
                     - I 6      2      5                     
                     2                                       
    - -------------------------------------------------------
         (1/2) / 1     (1/2)  (1/2)     1    (1/2)    \\
      tanh|- 5      |--- I 6      2      x + - t 5      + 1||
          \5        \ 24                     4             //

                      1    (1/2)  (1/2)  (1/2)                
                      - I 6      2      5                     
                      4                                       
    - --------------------------------------------------------
                                                             2
          (1/2) / 1     (1/2)  (1/2)     1    (1/2)    \\ 
      tanh|- 5      |--- I 6      2      x + - t 5      + 1|| 
               \ 24              4             // 


plot3d(Im(u[0]), x = -10 .. 10, t = -10 .. 10);

Dear all

I solve the first-order PDE with a boundary condition contains a parameter  s

When I run the code there is no solution displayed using pdsolve

Many thanks for your help

 

 

 

PDEBCS.mw

How do I solve an overdetermined system of algebraic equations in Maple? solve command returns trivial solution for variables which are not actually trivial when I solve them by hand.

Hi all

When I solve using maple the first-order differential equation: diff(y,x)=0  for x in the closed interval [0,1] we obtain a constant function as a solution

but one can define the piecewise constant function see please the attached code

diff_piecewise.mw

why when we differentiate the piecewise function gives undefined derivative at point zero and a half.

Whats is the relationship between this example and Existence and uniqueness theorem for fist order ode

Many thanks

 

 

 

The solution to the logistic map .The solution now oscillates but doesn't appear to show any discernible pattern. The value of Xn seems to "jump around". This  called chaotic.

Dear all

I have an first-order ode

y'(x) =0, for x in [0,1] but x different to 1/2

and we define a function y(x)= 2   if 0<=x<0.5  and y(x)=0 for 0.5<=x <=1

The attached code define these function ( maybe piecewise function is not welle defined) and how can we show that y is solution or not of the differential equation

ode.mw

many thanks

 

Hi all; 

Given two vectors C1 and C2.
Under what condition on C1 and C2,  the two matrices D1 and D2 are equal.

condition.mw

 

many thanks for your help

Hi

Can maple compute the following integral

Integral ( z^(-0.5), z in M) where  M is the lower half-unit circle from +1 to -1

Many thanks

 

Hi

I have a solution obtained using

sol:=pdsolve(PDE,BC);

"sol" is a function depend on variable x,

how can I differentiate this sol ( which a function ) then plot it

many thanks

 

Hello,

I'm trying to verify a computation using maple. But the simplification of Physics doesn't return the right value.

The computation is

I wrote the follow code


 

J[x]^2*J[z]^2+(J[x]*J[z]*J[x])*J[z]+J[x]*J[z]^2*J[x]+J[x]^2*J[z]*J[z]+(J[x]*J[z]*J[z])*J[x]+J[x]^2*J[z]^2 = 3*J[x]^2*J[z]^2+3*J[x]^2*J[z]^2+2*J[x]^2-3*J[y]^2+2*J[z]^2

``

restart; with(Physics)*Setup(noncommutativepre = J)

CommuRules := seq(op([%Commutator(J[j[1]], J[j[2]]) = I*J[j[3]]]), j = [[x, y, z], [y, z, x], [z, x, y]])

NULL

NULL

Setup(CommuRules)

[algebrarules = {%Commutator(J[x], J[y]) = I*J[z], %Commutator(J[y], J[z]) = I*J[x], %Commutator(J[z], J[x]) = I*J[y]}]

(1)

NULL

with(combinat)

np := numbperm([J[x], J[x], J[z], J[z]], 4)

6

(2)

``

``

L := permute([J[x], J[x], J[z], J[z]], 4)

[[J[x], J[x], J[z], J[z]], [J[x], J[z], J[x], J[z]], [J[x], J[z], J[z], J[x]], [J[z], J[x], J[x], J[z]], [J[z], J[x], J[z], J[x]], [J[z], J[z], J[x], J[x]]]

(3)

``

NULL

L2 := seq(map(proc (x, y, z, t) options operator, arrow; x*y*z*t end proc, op(L[i])), i = 1 .. np)

Physics:-`*`(Physics:-`^`(J[x], 2), Physics:-`^`(J[z], 2)), Physics:-`*`(J[x], J[z], J[x], J[z]), Physics:-`*`(J[x], Physics:-`^`(J[z], 2), J[x]), Physics:-`*`(J[z], Physics:-`^`(J[x], 2), J[z]), Physics:-`*`(J[z], J[x], J[z], J[x]), Physics:-`*`(Physics:-`^`(J[z], 2), Physics:-`^`(J[x], 2))

(4)

S := add(j, j = L2)

Physics:-`*`(Physics:-`^`(J[x], 2), Physics:-`^`(J[z], 2))+Physics:-`*`(J[x], J[z], J[x], J[z])+Physics:-`*`(J[x], Physics:-`^`(J[z], 2), J[x])+Physics:-`*`(J[z], Physics:-`^`(J[x], 2), J[z])+Physics:-`*`(J[z], J[x], J[z], J[x])+Physics:-`*`(Physics:-`^`(J[z], 2), Physics:-`^`(J[x], 2))

(5)

NULL

NULL

S1 := Simplify(S, algebrarules)

-(3*I)*Physics:-`*`(J[x], J[y], J[z])-7*Physics:-`^`(J[z], 2)-(8*I)*Physics:-`*`(J[z], J[x], J[y])+6*Physics:-`*`(Physics:-`^`(J[z], 2), Physics:-`^`(J[x], 2))-I*Physics:-`*`(J[y], J[z], J[x])

(6)

NULL

NULL

``


 

Download MapleCode.mw

 


If someone knows, or have suggestions that what i can do to find the right result, plz let me know

First 23 24 25 26 27 28 29 Last Page 25 of 88