Are you the publisher? Claim or contact us about this channel

Embed this content in your HTML


Report adult content:

click to rate:

Account: (login)

More Channels

Channel Catalog

Channel Description:

The most recent questions and posts on MaplePrimes tagged with perturbation
    0 0
  • 05/25/14--03:40: how to solve by vim or DTM?
  • hi dears. i cant solve this question by Analytical method such variational itteration method (VIM) or homotopy perturbation method (HPM), homotopy analysis method(HAM)

      1)  diff(f(eta),eta$3)+(1)/(2)*f(eta)*diff(f(eta),eta$2- K* (diff(f(eta),eta)-1)=0



    boundary conditions: 1)  f(0) = 0   2)  D(f)(0) = 0   3)  D(f)(infinity=10) = 1



    0 0

    Hello everyone,

    I've been trying to do some perturbation theory and ran into some problems I don't quite understand. I implemented the Hamiltonian of the Bose-Hubbard model and treated the hopping as a perturbation. Calculating the second order energy shift is easily accomplished, but when I'm only interested in one of the two occuring terms, I run into problems. The calculation takes minutes to finally fail, giving me an "too many levels of recursion"-error. I need to be able to just pick a few terms for some calculations, I'm doing, and can't figure out what I might be doing wrong. Here is the source code (download is below):

    restart; with(Physics); Setup(mathematicalnotation = true)

    a__1 := Annihilation(N, 1):

    assume(`and`(`in`(m, nonnegint), m > 0)):

    Physics:-Ket(N, m, m)


    H := Physics:-`*`(Physics:-`*`(1/2, n__1), n__1-1)+Physics:-`*`(Physics:-`*`(1/2, n__2), n__2-1):

    `ΔE__2` := Physics:-`*`(Physics:-`*`(2, d), simplify(value(Typesetting:-delayDotProduct(Typesetting:-delayDotProduct(Typesetting:-delayDotProduct(Typesetting:-delayDotProduct(Dagger(psi), V), 1/(E(m, m)-H)), V), psi))))



    simplify(value(((Dagger(psi).c__2)*a__1.(1/(E(m, m)-H)).c__1)*a__2.psi))

    Error, (in PatternMatching:-AlgStruct:-Match) too many levels of recursion




    It would be great, if someone could point out the mistake, I'm making. I copy/pasted the last line, so there shouldn't be any typos.

    Thanks in advance,


    0 0


    I seem to run into problems with (quantum) perturbation theory. In the following minimal working example, an energy denominator, as occuring in perturbation theory is not evaluated if I previously assume that the quantum number is a positive integer. It's supposed to return an error, as the energy denominator is 0.

    restart; with(Physics)

    a := Annihilation(N, 1, notation = explicit):

    psi := Ket(N, m);

    Physics:-Ket(N, m)


    E := proc (g) options operator, arrow; (1/2)*g*(g-1)-mu*g end proc:

    simplify(value(Typesetting:-delayDotProduct(Typesetting:-delayDotProduct(Dagger(psi), 1/(E(m)-H)), psi)))



    assume(`in`(m, nonnegint), m > 0);

    simplify(value(Typesetting:-delayDotProduct(Typesetting:-delayDotProduct(Dagger(psi), 1/(E(m)-H)), psi)))

    -2*Physics:-Bracket(Physics:-Bra(N, m), 1/(-2*mu*Physics:-`*`(`a-`[N[1]], `a+`[N[1]])+2*mu*m-m^2+Physics:-`*`(Physics:-`^`(`a-`[N[1]], 2), Physics:-`^`(`a+`[N[1]], 2))-4*Physics:-`*`(`a-`[N[1]], `a+`[N[1]])+2*mu+m+2), Physics:-Ket(N, m))


    Parse:-ConvertTo1D, "invalid input %1", `.`(Dagger(psi), 1/(E-H), psi)






    Best regards,


    0 0

    HPM_4.mwhi, I am using homotopy perturbation technique but there is arising an error in comaring coeffecient of p^0, p^1,.... plz help me


    0 0
  • 05/28/16--02:31: Problem with HPM
  • Hi everyone.

    I'm going to solve a problem with HPM in Maple. I wrote some initial codes but now I'm confused becouse of P^0 coefficients in A1 and B1. I mean I can't reach to f0 and g0.

    I upload that file. these are codes that i typed. could you please help me how can I reach to them(f0 & g0)?

    0 0
  • 06/16/16--19:59: Metric Perturbation
  • Hi All, 

    I'm using the Physics package, which enables GR calculations, ie defining metrics and tensor algebra. 

    Was just curious if it were possible to add a perturbation to the metric when calculating Ricci and Christoffels. 

    I would like something like 

    g_[] = g1_[mu,nu] + h[mu,nu] 

    And then do a calculation like, 



    I know this would be possible if I define everything and re-write the calculations for calculating Ricci, i.e

    Define(g1[mu,nu], h[mu,nu]); 

    and the proceed with GR calculations to find Ricci, however was hoping there was an easier way to do this. 

    Any help is appreciated. 

    Thanks guys. 

    0 0

    Please help me to solve the system of 1st order singular O.D.E  (see uploaded file)....New_Microsoft_Office_Word_Document.docx

    0 0
  • 05/25/14--03:40: how to solve by vim or DTM?
  • hi dears. i cant solve this question by Analytical method such variational itteration method (VIM) or homotopy perturbation method (HPM), homotopy analysis method(HAM)

      1)  diff(f(eta),eta$3)+(1)/(2)*f(eta)*diff(f(eta),eta$2- K* (diff(f(eta),eta)-1)=0



    boundary conditions: 1)  f(0) = 0   2)  D(f)(0) = 0   3)  D(f)(infinity=10) = 1



    0 0
  • 03/23/18--13:41: perturbation theorie
  • Hi all, I am having the follwing DE:

    (diff(z(x), x, x))-z(x) - cos(2*x)/(1+delta*z(x)) = 0:

    With initial conditions: z(-pi/4)=z(pi/4)=0 and |delta|<<1

    I showed by hand by using perturbation theory the second order approximation. The hint was: you can use Maple to check your answer. 

    Is there somebody who can help me with this?



    0 0

    I am working with the following differential equation:

    $\frac{d^2z}{dx^2}+z=\frac{\cos 2x}{1+\epsilon z},\:\:\:z(-\pi/4)=z(\pi/4)=0$

    where modulus of $\epsilon$ is much less than $1$.  The task is then to use perturbation theory (with Maple, if necessary) to show that the second-order approximation to the solution to this DE is:

    $z=-\frac{1}{3}\cos 2x +\epsilon\bigg(\frac{1}{6}-\frac{8\sqrt{2}}{45}\cos x - \frac{1}{90}\cos 4x \bigg) + \epsilon^2 \bigg(\frac{2\sqrt{2}x}{45}\sin x - \frac{\sqrt{2}}{90}(\pi + 1)\cos x + \frac{7}{720} \cos 2x - \frac{\sqrt{2}}{90}\cos 3x - \frac{1}{1050}\cos 6x \bigg).$

    I will then likely have to use Maple to determine the third-order term $\delta^{3}z_{3}(x)$ and evaluate $z_{3}(x)$ at $x=0$ and $x-\pi/8$.

    My starting point is to use the theory for a regular perturbation (since the modulus of $\epsilon$ is much less than $1$).  For the unperturbed equation, I could set $\epsilon=0$ as that would give a simple differential equation which should be solvable.  I can then see that $1/{1+\epsilon z}$ can be expanded to second-order in $\epsilon$ as $1 - \epsilon z + \epsilon^2 z^2 + O(\epsilon^3), which looks promising.  Could someone advise how I put this together?  Do I then have to multiply the unperturbed solution by the expansion in $\epsilon$? 

    0 0

    Dear sir / madam

    I'm a student of mechanical engineering and looking for some HPM ( homotopy perturbation method) maple codes with the related article to practice more in this field.
    can I ask you for help?
    unfortunately, I couldn't find any articles with maple solution about HPM.