Items tagged with differential differential Tagged Items Feed


The PDE & BC project , a very nice and challenging one, also one where Maple is pioneer in all computer algebra systems, has restarted, including now also the collaboration of Katherina von Bülow.

Recapping, the PDE & BC project started 5 years ago implementing some of the basic methods found in textbooks to match arbitrary functions and constants to given PDE boundary conditions of different kinds. At this point we aim to fill gaps, and the first one we tackled is the case of 1st order PDE that can be solved without boundary conditions in terms of an arbitrary function, and where a single boundary condition (BC) is given for the PDE unknown function, and this BC does not depend on the independent variables of the problem. It looks simple ... It can be rather tricky though. The method we implemented is a simple however ingenious use of differential invariants  to match the boundary condition.


The resulting new code, the portion already tested, is available for download in the Maplesoft R&D webpage for Differential Equations and Mathematical Functions (the development itself is bundled within the library that contains the new developments for the Physics package, in turn within the zip linked in the webpage).


The examples that can now be handled, although restricted in generality to "only one 1st order linear or nonlinear PDE and only one boundary condition for the unknown function itself", illustrate well how powerful it can be to use more advanced methods to tackle these tricky situations where we need to match an arbitrary function to a boundary condition.


To illustrate the idea, consider first a linear example, among the simplest one could imagine:

PDEtools:-declare(f(x, y, z))

f(x, y, z)*`will now be displayed as`*f

(1)

pde := diff(f(x, y, z), x)+diff(f(x, y, z), y)+diff(f(x, y, z), z) = f(x, y, z)

diff(f(x, y, z), x)+diff(f(x, y, z), y)+diff(f(x, y, z), z) = f(x, y, z)

(2)

Input now a boundary condition (bc) for the unknownf(x, y, z) such that this bc does not depend on the independent variables {x, y, z}; this bc can however depend on arbitrary symbolic parameters, for instance

bc := f(alpha+beta, alpha-beta, 1) = alpha*beta

f(alpha+beta, alpha-beta, 1) = alpha*beta

(3)

With the recent development, this kind of problem can now be solved in one go:

sol := pdsolve([pde, bc])

f(x, y, z) = (1/4)*(x-2*z+2+y)*(x-y)*exp(z-1)

(4)

Nice! And how do you verify this result for correctness? With pdetest , which actually also tests the solution against the boundary conditions:

pdetest(sol, [pde, bc])

[0, 0]

(5)

And what has been done to obtain the solution (4)? First the PDE was solved regardless of the boundary condition, so in general, obtaining:

pdsolve(pde)

f(x, y, z) = _F1(-x+y, -x+z)*exp(x)

(6)

In a second step, the arbitrary function _F1(-x+y, -x+z) got determined such that the boundary condition f(alpha+beta, alpha-beta, 1) = alpha*beta is matched. Concretely, the mapping _F1 is what got determined. You can see this mapping reversing the solving process in two steps. Start taking the difference between the general solution (6) and the solution (4) that matches the boundary condition

(f(x, y, z) = _F1(-x+y, -x+z)*exp(x))-(f(x, y, z) = (1/4)*(x-2*z+2+y)*(x-y)*exp(z-1))

0 = _F1(-x+y, -x+z)*exp(x)-(1/4)*(x-2*z+2+y)*(x-y)*exp(z-1)

(7)

and isolate here _F1(-x+y, -x+z)

PDEtools:-Solve(0 = _F1(-x+y, -x+z)*exp(x)-(1/4)*(x-2*z+2+y)*(x-y)*exp(z-1), _F1(-x+y, -x+z))

_F1(-x+y, -x+z) = (1/4)*exp(-x+z-1)*(x^2-2*x*z-y^2+2*y*z+2*x-2*y)

(8)

So this is the value _F1(-x+y, -x+z) that got determined. To see now the actual solving mapping _F1, that takes for arguments -x+y and -x+z and returns the right-hand side of (8), one can perform a change of variables introducing the two parameters `τ__1` and `τ__2` of the _F1 mapping:

{tau__1 = -x+y, tau__2 = -x+z, tau__3 = z}

{tau__1 = -x+y, tau__2 = -x+z, tau__3 = z}

(9)

solve({tau__1 = -x+y, tau__2 = -x+z, tau__3 = z}, {x, y, z})

{x = -tau__2+tau__3, y = -tau__2+tau__1+tau__3, z = tau__3}

(10)

PDEtools:-dchange({x = -tau__2+tau__3, y = -tau__2+tau__1+tau__3, z = tau__3}, _F1(-x+y, -x+z) = (1/4)*exp(-x+z-1)*(x^2-2*x*z-y^2+2*y*z+2*x-2*y), proc (u) options operator, arrow; simplify(u, size) end proc)

_F1(tau__1, tau__2) = -(1/4)*exp(tau__2-1)*tau__1*(tau__1-2*tau__2+2)

(11)

So the solving mapping _F1 is

_F1 = unapply(rhs(_F1(tau__1, tau__2) = -(1/4)*exp(tau__2-1)*tau__1*(tau__1-2*tau__2+2)), tau__1, tau__2)

_F1 = (proc (tau__1, tau__2) options operator, arrow; -(1/4)*exp(tau__2-1)*tau__1*(tau__1-2*tau__2+2) end proc)

(12)

Wow! Although this pde & bc problem really look very simple, this solution (12) is highly non-obvious, as is the way to get it just from the boundary condition f(alpha+beta, alpha-beta, 1) = alpha*beta and the solution (6) too. Let's first verify that this mapping is correct (even when we know, by construction, that it is correct). For that, apply (12) to the arguments of the arbitrary function and we should obtain (8)

(_F1 = (proc (tau__1, tau__2) options operator, arrow; -(1/4)*exp(tau__2-1)*tau__1*(tau__1-2*tau__2+2) end proc))(-x+y, -x+z)

_F1(-x+y, -x+z) = -(1/4)*exp(-x+z-1)*(-x+y)*(x-2*z+2+y)

(13)

Indeed this is equal to (8)

normal((_F1(-x+y, -x+z) = -(1/4)*exp(-x+z-1)*(-x+y)*(x-2*z+2+y))-(_F1(-x+y, -x+z) = (1/4)*exp(-x+z-1)*(x^2-2*x*z-y^2+2*y*z+2*x-2*y)))

0 = 0

(14)

Skipping the technical details, the key observation to compute a solving mapping is that, given a 1st order PDE where the unknown depends on k independent variables, if the boundary condition depends on k-1 arbitrary symbolic parameters alpha, beta, one can always seek a "relationship between these k-1parameters and the k-1differential invariants that enter as arguments in the arbitrary function _F1 of the solution", and get the form of the mapping _F1 from this relationship and the bc. The method works in general. Change for instance the bc (3) making its right-hand side be a sum instead of a product

bc := f(alpha+beta, alpha-beta, 1) = alpha+beta

f(alpha+beta, alpha-beta, 1) = alpha+beta

(15)

sol := pdsolve([pde, bc])

f(x, y, z) = (x-z+1)*exp(z-1)

(16)

pdetest(sol, [pde, bc])

[0, 0]

(17)

An interesting case happens when the boundary condition depends on less than k-1 parameters, for instance:

bc__1 := subs(beta = alpha, bc)

f(2*alpha, 0, 1) = 2*alpha

(18)

sol__1 := pdsolve([pde, bc__1])

f(x, y, z) = ((x-z+1)*_C1+x-y)*exp(((z-1)*_C1+y)/(1+_C1))/(1+_C1)

(19)

As we see in this result, the additional difficulty represented by having few parameters got tackled by introducing an arbitrary constant _C1 (this is likely to evolve into something more general...)

pdetest(sol__1, [pde, bc__1])

[0, 0]

(20)

Finally, consider a nonlinear example

PDEtools:-declare(u(x, y))

u(x, y)*`will now be displayed as`*u

(21)

pde := 3*(u(x, y)-y)^2*(diff(u(x, y), x))-(diff(u(x, y), y)) = 0

3*(u(x, y)-y)^2*(diff(u(x, y), x))-(diff(u(x, y), y)) = 0

(22)

Here we have 2 independent variables, so for illustration purposes use a boundary condition that depends on only one arbitrary parameter

bc := u(0, alpha) = alpha

u(0, alpha) = alpha

(23)

All looks OK, but we still have another problem: check the arbitrary function _F1 entering the general solution of pde when tackled without any boundary condition:

pdsolve(pde)

u(x, y) = RootOf(-y^3+3*y^2*_Z-3*y*_Z^2+_Z^3-_F1(_Z)-x)

(24)

Remove this RootOf to see the underlying algebraic expression

DEtools[remove_RootOf](u(x, y) = RootOf(-y^3+3*y^2*_Z-3*y*_Z^2+_Z^3-_F1(_Z)-x))

-y^3+3*y^2*u(x, y)-3*y*u(x, y)^2+u(x, y)^3-_F1(u(x, y))-x = 0

(25)

So this is a pde where the general solution is implicit, actually depending on an arbitrary function of the unknown u(x, y) The code handles this problem in the same way, just that in cases like this there may be more than one solution. For this very particular bc (23) there are actually three solutions:

pdsolve([pde, bc])

u(x, y) = x^(1/3)+y, u(x, y) = -(1/2)*x^(1/3)-((1/2)*I)*3^(1/2)*x^(1/3)+y, u(x, y) = -(1/2)*x^(1/3)+((1/2)*I)*3^(1/2)*x^(1/3)+y

(26)

Verify these three solutions against the pde and the boundary condition

map(pdetest, [u(x, y) = x^(1/3)+y, u(x, y) = -(1/2)*x^(1/3)-((1/2)*I)*3^(1/2)*x^(1/3)+y, u(x, y) = -(1/2)*x^(1/3)+((1/2)*I)*3^(1/2)*x^(1/3)+y], [pde, bc])

[[0, 0], [0, 0], [0, 0]]

(27)

:)


Download PDEs_and_Boundary_Conditions.mw

Edgardo S. Cheb-Terrab
Physics, Differential Equations and Mathematical Functions, Maplesoft

Good day everyone,

 

I want to construct groebner bases over rings of differential Operators.

Thus I used the following:

 

with(Ore_algebra);

with(Groebner); N := 3;

A := skew_algebra(diff = [D[1], x[1]], diff = [D[2], x[2]], diff = [D[3], x[3]], comm = i, alg_relations = i^2+1); T := MonomialOrder(A, tdeg(D[1], D[2], D[3]));

A["polynomial_indets"];  [returns    {D[1], D[2], D[3]}]

A["rational_indets"];       [returns    {i, x[1], x[2], x[3]}]

 

So far everything seems as it should be: The ring i wanted to define here is the third Ring of  Differential operators over the field of complex 'rational' functions and maple returns that indeed it will handle the D[i] as monomials and the rest as coefficients for them.

 

Hover, when i use the Skew product, the following happens:

skew_product(x[1],D[1],A)                    [returns D[1]x[1]+1}]

skew_product(x[1],D[1],A)                    [returns D[1]x[1]]

Both is wrong, but maple seems to 'know' this. It used the correct relation to in the first product, the only thing it didn't do was switch D[1] and x[1]. I think maple handles the result of the skew product as if it was a commutative product and always places the D[i] at the left but still 'knows' what the actual result is.

The actual results should have been x[1]D[1]+1 for the first and x[1]*D[1] for the second product.

 

In the second product, it seems like maple treated x[1]*D[1] as if the Elements were switched already.

 

What i want though is for maple to correctly display the skew products and return the products so that in every summand the D[i] are at the right side and their coefficients are at the left side (and if possible (i do not know how to do that yet) sort the result of a skew product in a way that displays every different Power product of the D[i] with their coefficients, so that i get (x[1]+x[2])*D[2] and not x[1]*D[2]+x[2]*D[2]).

 

Can anyone help me here?

 


                              
                     
                   
                 

Is it possible to somehow extract a derivative from numeric solution of partial differential equation?

I know there is a command that does it for dsolve but i couldn't find the same thing for pdsolve.

The actual problem i have is that i have to take a numeric solution, calculate a derivative from it and later use it somewhere else, but the solution that i have is just a set of numbers an array of some sort and i can't really do that because obviously i will get a zero each time.

Perhaps there is a way to interpolate this numeric solution somehow?

I found that someone asked a similar question earlier but i couldn't find an answer for it.

How to solve delay differential equations with Maple?

Example:

diff(x(t),t) = 3*x(t)^2 + 0.3*x(x-0.03)

Hello everyoene, please i have a problem solving this delay differential equation:

y'(x)=cos(x)+y(y(x)-2)    0<x<=10

y(x)=1      x<=0

tau=x-y(x)+2

please i need the solution urgently

http://www.gap-system.org/Manuals/doc/ref/chap50.html

 

which group do four differential electromagnetism belong to in library available in gap system? 

what is the order of the group?

do maple 17 have this group? how to show?

guys ,

in a differential equation i want to expand its variable, but i  have some problem with it for exponential term :jadid.mw

 

 

thanks guys

 

 

How to find the determining equation for a system of fractional differential equation using Maple 15?

How do i proceed to solve two differential equations?

Two equations two unknowns is easy to solve in polynomial algebraic equations. Example: x+y=5; x-y=3; The solution is x=4; y=1 by adding the equations we arrive at.

The two equations are second order differential equations with two variables say temperature T (x,y) and velocity c(x,y). Assume any simple equation (one dimensional as well i.e. T(x) and c(x) which you can demonstrate with ease, I have not formulated the exact equations and boundary conditions yet for SI Engine simulation.

Thanks for comments, suggestions and answers expected eagerly.

Ramakrishnan

Hi,

I am trying to realize the following calculation in Maple.

$
  \left[\sum_{i=0}^n y_i(x) \partial_x^i , \sum_{j=0}^m z_j(x) \partial_x^j \right]  \\
=   \sum_{i=0}^n \sum_{j=0}^m \sum_{l=0}^i  \binom il y_i(x) \left( \partial_x^{i-l} z_j(x)\right) \partial_x^{l+j} \\
- \sum_{j=0}^m \sum_{i=0}^n \sum_{l=0}^j  \binom jl z_j(x) \left( \partial_x^{j-l} z_i(x)\right) \partial_x^{l+i} \ .

$

 

Is there a way to make maple understand d/dx as a differential opperator and calculate with it? When i for example try to calculate diff(d/dx, x) it should give me d^2/dx^2 as a result. Unfortunately i don't know how to realize this.

Basic problem is i don't know how to realize operator expressions in maple like for example:

f(x) d/dx      ( f(x) is a smooth function of x here )

where when applied to a function h(x) it should result in f(x) d/dx h(x) .

 

Is that possible?

 

Thank you very much in advance.

In this section, we will consider several linear dynamical systems in which each mathematical model is a differential equation of second order with constant coefficients with initial conditions specifi ed in a time that we take as t = t0.

All in maple.

 

Vibraciones.mw

(in spanish)

 

Atte.

L.AraujoC.

Hi everybody!

It's nice to join in this forum.

I'm trying to get the analytic solution of the Bernouilli-Euler beam equation, with the next boundary conditions:


w(x,t) = displacements.

w(0,t) = 0   -> It's a cantilever beam. At the x=0 it's clamped.

diff(w(x,t),x) = 0.   -> the gyro in the clamp is zero.

E*I*diff(w(L,t),x,x) = 0  -> the moment at the end of the beam (x=L) is zero.

E*I*diff(w(L,t),x,x,x) = 0  -> the shear at the end of the beam (x=L) is zero too.


I'm not able to introduce the second and the third derivatives as boundary conditions in the pdsolve equation. I post the hole code:

restart;
ode := I*E*(diff(w(x, t), x, x, x, x))+m*(diff(w(x, t), t, t)) = 0;

s := pdsolve(ode, w(x, t));

ode1 := op([2, 1, 1], s);

ode2 := op([2, 1, 2], s);

f1 := op(4, rhs(ode1));

f2 := op(2, rhs(ode2));

sol1 := dsolve(ode1, f1);

sol2 := dsolve(ode2, f2);

sol := rhs(sol1)*rhs(sol2);

conds := [w(0, t) = 0, (D[1](w))(0, t) = 0, eval(I*E*(D[1, 1](w))(x, t), x = L) = 0, eval(I*E*(D[1, 1, 1](w))(x, t), x = L) = 0];

pde := [ode, conds];

pdsolve(pde, w(u, t));


And I get this error:

"Error, (in PDEtools/pdsolve) invalid input: `pdsolve/sys` expects its 1st argument, SYS, to be of type {list({`<>`, `=`, algebraic}), set({`<>`, `=`, algebraic})}, but received [I*E*(diff(diff(diff(diff(w(x, t), x), x), x), x))+m*(diff(diff(w(x, t), t), t)) = 0, [w(0, t) = 0, (D[1](w))(0, t) = 0, I*E*(D[1, 1](w))(L, t) = 0, I*E*(D[1, 1, 1](w))(L, t) = 0]]"


It's seems I'm introducing the Boundary conditions of the second and third derivatives in a wrong way, but I can't discover how to do it.

Thanks very much in advance to everybody!!

Ger89



P.D. - I have use this "tutorial" to write the code ( http://homepages.math.uic.edu/~jan/mcs494f02/Lec34/pde.html ). Thanks very much again. 

 

Hello there, could someone tell me how to input this differential equation?

d2x/dt2 - (3)dx/dt + 2x = 2t -3 

x=2, t=0, dx/dt=4

Hi there,

I'm trying to get the values from the output of a dsolve command.

I have a system of differential equations:

de1 := diff(V(t), t) = V(t)-(1/3)*V(t)^3-W(t)+Ie;
de2 := diff(W(t), t) = 0.8e-1*(V(t)+.7-.8*W(t))

For a range of the independent variable t and for some given values of the parameter Ie, I would like to get the value of the dependent variable V, as well as its minimum/maximum values for each Ie.

Can anybody suggest a solution please?

 

This is the worksheet: MaplePrimes_dsolve_min-max.mw

 

Thanks,

jon

At the internet site of The Heun Project, a strong declaration is made that only Maple incorporates Heun functions, which arise in the solution of differential equations that are extremely important in physics, such as the solution of Schroedinger's equation for the hydrogen atom.  Indeed solutions appear in Heun functions, which are highly obscure and complicated to use because of their five or six arguments, but when one tries to convert them to another function, nothing seems to work.  For instance, if one inquires of FunctionAdvisor(display, HeunG), the resulting list contains

"The location of the "branch cuts" for HeunG are [sic, is] unknown ..." followed by several other "unknown" and an "unable". Such a solution of a differential equation is hollow.

Incidentally, Maple's treatment of integral equations is very weak -- only linear equations with simple solutions, although procedures by David Stoutemyer from 40 years ago are available to enhance this capability.

When can we expect these aspects of Maple to work properly, for applications in physics?

1 2 3 4 5 6 7 Page 1 of 8