# User:Fuse809

 This user has been on Wikipedia for 7 years, 9 months and 3 days.
 WP:RS This user believes in using Reliable Sources.
 This user edits with the gadget wikEd.
 OED This user uses Oxford spelling.
 INN This user favours the use of International Nonproprietary Names (INNs), as designated by the World Health Organization, over all over generic names, in all circumstances.
Software
 This user presently contributes using theLinux distributions: Arch, NixOS and openSUSE Tumbleweed. Although, he has used other distributions in the past to contribute to Wikipedia.
 This user contributes with GNOME.
 This user contributes with KDE desktop environment.
 This user contributes using i3.
 This user contributes using Firefox.
 This user contributes using GIMP.
 This user contributes using Inkscape.

## My chemical structures

I create structural images to satisfy everyone, not just me. I try to use the structures provided by ChemSpider or PubChem just to ensure reliability. The software I use for chemical structure drawing is (beware User:Vaccinationist has been editing my files, contrary to my wishes, so some with the filenames described bellow may no longer be mine):

• MarvinSketch/ChemSpider/PubChem (for the production of MOL files), ChemSketch (to create WMF files in ACS style) and then Scribus to convert the WMF to a SVG file (these are the images with 2DACS tags).
• MarvinSketch (with settings according to WP:Chem/Structures) to create SVG files (2DCSD tag). Sometimes I do these images wrong the first time in that I do not crop them as well as I can and when I upload a better scaled cropped version I give it the tag 2DCSDS. Structures drawn in MarvinSketch often have whitespace in their atom labels that are due to MarvinSketch itself, e.g., see this forum topic I started about these spaces. The best solution for removing them is to use a text editor (e.g., Atom or Sublime Text) and search for xml:space="preserve"  and replace it with nothing (in other words set the text editor up such that it deletes all these pieces of XML code). After this I use Inkscape to crop them. Sometimes I accidentally draw the opioids in a less conventional way, so when I fix this I give them the tag 2DCSDT.
• MarvinSketch (to create SDF files) → OpenBabel (SDF->PDB; also adds hydrogens with this tool) → QuteMol (PDB->GIF). (3Dan tag). Unfortunately these images do not display double bonds in a way distinct from single bonds and hence I'm now favouring the 3DanJ images.
• I also create 3D animated GIF files of drug molecules using Jmol (to create usually about 60 PNG images spaced 3 degrees apart) and GIMP to animate them into gif files. (3DanJ tag). This is the code I use to create these images:
background white;##
name = "./images/Work0000.png";
nFrames = 60;
nDegrees =6 ;
thisFrame = 0;
width = 539;
height = 260;

message loop;
thisFrame = thisFrame + 1;
fileName = name.replace("0000","" + ("0000" + thisFrame)[-4][0]);
rotate y @ndegrees;
frame next; # only use this if you have a multiframe file.
refresh;
write image @width @height @fileName;
if (thisFrame < nFrames);goto loop;endif;

• I create 3D animated pictures of biomolecules, most often joined with their respective ligand(s) using the PDB files found here, Jmol and then PhotoScape or GIMP to convert these PNG images to GIF format. I usually colour shapely, unless doing so will make the ligand(s) difficult to see. I have now decided to use the name PDBID3DanJ for these images; for instance, https://en.wikipedia.org/wiki/File:3NT13DanJ.gif for this protein-ligand complex 3NT1.
Structures (Hidden as one of the animated images is insanely high resolution)
Image type Example's name Image example
2DACS Piritramide
2DCSD Dextropropoxyphene
3Dan Fluoxetine
3DanJ Piritramide
Biomolecule High resolution structure of naproxen:COX-2 complex. (PDB ID:3NT1)

I upload all these images to commons now, as per the request by Leyo on my talk page. For a comprehensive list of images I've uploaded see Commons:Special:ListFiles/Fuse809.

## Proof that a projectile will travel in a parabola

Note: this is using some basic energy conservation laws of physics.
Assumptions: acceleration due to gravity (${\displaystyle g={\frac {GM}{r^{2}}}}$) does not vary substantially with position along the trajectory. Air resistance is negligible and wind is non-existent.

With the Hamiltonian:

Figure 2: William Rowan Hamilton (1805-1865), the Irish physicist and mathematician after whom the Hamiltonian is named.
${\displaystyle {\mathcal {H}}=T+V}$

also known as the total energy of the system. Where T is kinetic energy (${\displaystyle {\frac {mv^{2}}{2}}}$); V is potential energy (${\displaystyle mgy}$). where: ${\displaystyle v^{2}={\dot {x}}^{2}+{\dot {y}}^{2}}$ and v is the velocity.

${\displaystyle {\mathcal {H}}={\frac {mv^{2}}{2}}+mgy}$

### Re-expressing v as a function of y

Basic energy conservation laws state that the Hamiltonian should be static, assuming a lack of drag. Therefore, H at one time should equal H at another time. So let us take t=0 where y=0 and v=v0 and equate it to the variable form of the Hamiltonian. That is:

${\displaystyle \therefore \ \ \ \ {\frac {mv_{0}^{2}}{2}}={\frac {mv^{2}}{2}}+mgy}$

${\displaystyle \ \ \ v^{2}=v_{0}^{2}-2gy}$

${\displaystyle \therefore \ \ \ \ \ \ \ \ v={\sqrt {v_{0}^{2}-2gy}}}$

### Expressing y in terms of x

Let, y be a function of x. That is let:

${\displaystyle y=y(x)}$

${\displaystyle \therefore }$ using the chain rule we get:

${\displaystyle {\dot {y}}={\frac {dy}{dt}}=y'(x){\dot {x}}}$

Where: ${\displaystyle {\dot {x}}={\frac {dx}{dt}};\ {\dot {y}}={\frac {dy}{dt}};\ y'(x)={\frac {dy}{dx}}}$

It follows with the substitution of this expression into our first expression for v2 we get:

${\displaystyle v^{2}={\dot {x}}^{2}(1+(y'(x))^{2})}$

### Equating results for v

Equating this expression with what we got from the law of conservation of energy we get:

${\displaystyle v_{0}^{2}-2gy={\dot {x}}^{2}(1+(y'(x))^{2})}$

As there is no forces in the x direction we can safely assume that ${\displaystyle {\dot {x}}}$ is constant, letting this constant be ${\displaystyle v_{0,x}}$ we can rearrange this equation to get:

${\displaystyle \ v_{0,y}^{2}-v_{0,x}^{2}(y'(x))^{2}=2gy}$

with some rearrangement we get:

${\displaystyle (y'(x))^{2}={\frac {v_{0,y}^{2}-2gy}{v_{0,x}^{2}}}}$

Identifying the ratio of the y and x velocities as ${\displaystyle \tan {\theta }}$ where ${\displaystyle \theta }$ is the launch angle of the projectile we get:

First order differential equation for y

${\displaystyle (y'(x))^{2}=\tan ^{2}{\theta }-{\frac {2gy}{v_{0,x}^{2}}}}$

Taking the square root of both sides gives:

${\displaystyle y'(x)=\pm {\sqrt {\tan ^{2}{\theta }-{\frac {2gy}{v_{0,x}^{2}}}}}}$

### Solving our first-order differential equation for y

Dividing through by the RHS and integrating with respect to x gives:

${\displaystyle \pm \int {\frac {dy}{\sqrt {\tan ^{2}{\theta }-{\frac {2gy}{v_{0,x}^{2}}}}}}=x+C}$

Integrating by substitution with: ${\displaystyle u=\tan ^{2}{\theta }-{\frac {2gy}{v_{0,x}^{2}}}}$, ${\displaystyle du=-{\frac {2g}{v_{0,x}^{2}}}dy}$, ${\displaystyle \therefore dy=-{\frac {v_{0,x}^{2}}{2g}}du}$

${\displaystyle {\frac {v_{0,x}^{2}}{2g}}\int u^{-1/2}du=\pm x+C}$

Solving this integral gives:

${\displaystyle \therefore \ \ \ \ \ \ \ \ \ \ \ \ \ {\frac {v_{0,x}^{2}}{g}}{\sqrt {u}}=\pm x+C}$

Squaring both sides and rearranging, gives:

${\displaystyle \therefore \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ \ u={\frac {g^{2}}{v_{0,x}^{4}}}(\pm x+C)^{2}}$

Back-substituting again gives:

${\displaystyle \therefore \ \ \ \ \ \ \tan ^{2}{\theta }-{\frac {2gy}{v_{0,x}^{2}}}={\frac {g^{2}}{v_{0,x}^{4}}}(\pm x+C)^{2}}$

Then with some rearranging:

${\displaystyle \ {\frac {2gy}{v_{0,x}^{2}}}=\tan ^{2}{\theta }-{\frac {g^{2}}{v_{0,x}^{4}}}(\pm x+C)^{2}}$

### Our solution for y

Solution for y

${\displaystyle \ y={\frac {v_{0,y}^{2}}{2g}}-{\frac {g}{2v_{0,x}^{2}}}(\pm x+C)^{2}}$

This equation is precisely the equation of a parabola, that is, ${\displaystyle y=ax^{2}+bx+c}$.

## Drag and projectile motion

Figure 3: An example trajectory, the green line denotes the closest fit a parabola can give to the trajectory.

When drag is taken into consideration there are two major possible corrections to the force acting on an object, Stokes' and Newton. Stokes' gives the correction ${\displaystyle {\vec {F}}=-b{\vec {v}}}$ whereas Newton gives ${\displaystyle {\vec {F}}=-av{\vec {v}}}$.[1] Therefore Newton's second law reduces to:
${\displaystyle m{\frac {d{\vec {v}}}{dt}}=m{\vec {g}}-b{\vec {v}}-av{\vec {v}}}$

Letting: ${\displaystyle \beta ={\frac {b}{m}};\ \alpha ={\frac {a}{m}}}$

${\displaystyle {\frac {d{\vec {v}}}{dt}}={\vec {g}}-\beta {\vec {v}}-\alpha v{\vec {v}}}$

Working in two dimensions (x and y), yields two equations:

${\displaystyle {\frac {dv_{x}}{dt}}=-\beta v_{x}-\alpha {\sqrt {v_{x}^{2}+v_{y}^{2}}}v_{x}}$   (1)

${\displaystyle {\frac {dv_{y}}{dt}}=-g-\beta v_{y}-\alpha {\sqrt {v_{x}^{2}+v_{y}^{2}}}v_{y}}$   (2)

Where ${\displaystyle v_{x}={\dot {x}}}$ and ${\displaystyle v_{y}={\dot {y}}}$ are the velocities in the x and y directions, respectively. These equations, being nonlinear coupled ordinary differential equations are impossible to solve in an exact (analytical) way, hence only numerical approximations are available. Letting, ${\displaystyle \alpha =0.016;\ \beta =1.024\times 10^{-5};\ D=0.08;\ g=9.8;\ m=0.1kg;\ v_{0,x}=10;\ v_{0,y}=10}$ (refer to the [1] for the reasons for these choices) where the units are given here and ${\displaystyle t\in [0,1.92]}$ and applying quadratic regression to the numerical solution gives the following MATLAB code and an estimate with a root mean square error of 0.068 metres.[1]

%dragcalc.m
clear all
options = odeset('RelTol',1e-10,'AbsTol',[1e-10 1e-10 1e-10 1e-10]);

%Using the ODE45 function http://www.mathworks.com.au/help/matlab/ref/ode45.html.

[t,x]=ode45(@drag,[0 1.92],[0 10 0 10],options);

N=length(t);
P=[ones(N,1) x(:,1) x(:,1).^2];
a=P\x(:,3); Pr=P*a;
err=(Pr-x(:,3)); rms=sqrt(err'*err/N);

%Plotting
plot(x(:,1),x(:,3),'r',x(:,1),Pr,'g')


Where the drag function is given by the following m file:

%drag.m
function dx=drag(t,x)
g=9.8; alf=0.016; bet=1.024e-5; %alf=alpha; bet=beta
dx(1,1)=x(2,1); %dx/dt
dx(2,1)=-alf*sqrt(x(2,1)^2+x(4,1)^2)*x(2,1)-bet*x(2,1); %d^2x/dt^2
dx(3,1)=x(4,1); %dy/dt
dx(4,1)=-g-alf*sqrt(x(2,1)^2+x(4,1)^2)*x(4,1)-bet*x(4,1); %d^2y/dt^2
end


## Proof that a satellite will travel in an elliptical path around a central mass

Figure 4: The elliptical orbit of a planet in orbit around the sun. The sun is at the focus of this ellipse.

### Conservation of energy

Let the Hamiltonian (which is the total energy of the system) be:

${\displaystyle {\mathcal {H}}=T+V}$

Where T and V are the kinetic and potential energies, respectively. Assuming we have the central mass at r=0 (the focus of the trajectory, although we do not know this quite yet as we are still to prove that the trajectory is elliptical in the first place), then:

${\displaystyle {\mathcal {H}}={\frac {m}{2}}\left({\dot {r}}^{2}+r^{2}{\dot {\theta }}^{2}\right)-{\frac {GMm}{r}}}$

(1)

Where G is the gravitational constant, which is approximately, ${\displaystyle 6.6738\times 10^{-11}\ {\textrm {N}}\cdot {\textrm {m}}^{2}\cdot {\textrm {kg}}^{-2}}$.[2] is the mass of the larger object, m is mass of the smaller object (like the particle in orbit). As always the dot above r or theta, indicates the derivative with respect to time, that is, the rate at which said coordinate changes with respect time. According to the law of the conservation of energy, this quantity should be static (i.e. constant) throughout the projectile's path.

### Substitutions galore to make our job easier

Now it is time for some substitutions to make our lives easier. Let: ${\displaystyle \alpha ^{2}={\frac {2{\mathcal {H}}}{m}}}$, ${\displaystyle \mu =GM}$. According to the law of the conservation of angular momentum ${\displaystyle L=mr^{2}{\dot {\theta }}={\textrm {constant}};\ {\dot {\theta }}={\frac {L}{mr^{2}}};\ \therefore \ r^{2}{\dot {\theta }}^{2}={\frac {L^{2}}{m^{2}r^{2}}}}$. Let: ${\displaystyle \beta ={\frac {L}{m}}}$, which is also a constant, provided m is constant, then ${\displaystyle r^{2}{\dot {\theta }}^{2}={\frac {\beta ^{2}}{r^{2}}}}$.

### Manipulating the Hamiltonian to get r dot

Multiplying (1) by ${\displaystyle {\frac {2}{m}}}$, gives:

${\displaystyle \alpha ^{2}={\dot {r}}^{2}+{\frac {\beta ^{2}}{r^{2}}}-{\frac {2\mu }{r}}}$

${\displaystyle \implies {\dot {r}}^{2}=\alpha ^{2}+{\frac {2\mu }{r}}-{\frac {\beta ^{2}}{r^{2}}}}$

### Extensive substitutions

To simplify this further, let: ${\displaystyle \rho ={\frac {1}{r}}}$ then:

${\displaystyle \ \ {\dot {\rho }}=-{\frac {\dot {r}}{r^{2}}}}$

(2)

${\displaystyle \therefore \ \ \ {\dot {r}}^{2}=\alpha ^{2}+2\mu \rho -\beta ^{2}\rho ^{2}}$

Let us call this expression on the right-hand side ${\displaystyle f(\rho )}$. We shall rearrange f so that it is easier for us to use later.

${\displaystyle f(\rho )=-\beta ^{2}\left(\rho ^{2}-{\frac {2\mu }{\beta ^{2}}}\rho -{\frac {\alpha ^{2}}{\beta ^{2}}}\right)}$

Let the expression in brackets be called ${\displaystyle g(\rho )}$. Making some further substitutions: ${\displaystyle \gamma ^{2}={\frac {\alpha ^{2}}{\beta ^{2}}};\ \nu ={\frac {\mu }{\beta ^{2}}};\ \xi =\rho -\nu ;\ \xi ^{2}=\rho ^{2}+\nu ^{2}-2\nu \rho }$. Then:

${\displaystyle g(\rho )=\xi ^{2}-\nu ^{2}-\gamma ^{2}}$

Let: ${\displaystyle \chi =\beta \xi ;\ \kappa ={\frac {\mu }{\beta ^{2}}}}$ then:

${\displaystyle f(\rho )=-\chi ^{2}+\kappa ^{2}+\alpha ^{2}}$

Two final substitutions are required, let: ${\displaystyle \omega ^{2}=\kappa ^{2}+\alpha ^{2}}$ and ${\displaystyle z={\frac {\chi }{\omega }}}$.

Inverting this, for future reference, gives:

${\displaystyle d\rho ={\frac {\omega }{\beta }}dz}$

(3)

Then:

${\displaystyle f(\rho )=\omega ^{2}(1-z^{2})}$

This, in turn gives:

${\displaystyle \therefore \ \ \ \ {\dot {r}}=\pm \omega {\sqrt {1-z^{2}}}}$

(4)

### Expressing theta in terms of rho

${\displaystyle \theta '={\frac {d\theta }{d\rho }}}$

${\displaystyle ={\frac {\dot {\theta }}{\dot {\rho }}}}$

(5)

${\displaystyle \therefore \ \ \ \ \theta '=-{\frac {\beta }{\dot {r}}}}$

Integrating with respect to rho gives:

${\displaystyle \ \ \theta =\mp \beta \int {\frac {d\rho }{\dot {r}}}}$

(6)

Substituting, into (6), (3) and (4) gives:

${\displaystyle \ \ \theta =\mp \beta \int {\frac {\omega }{\beta }}{\frac {dz}{\omega {\sqrt {1-z^{2}}}}}}$

(7)

These constants cancel out, giving:

${\displaystyle \ \ \theta =\pm \cos ^{-1}{z}}$

(8)

Back-substituting z gives: ${\displaystyle z={\frac {\beta }{\omega }}(\rho -\nu )}$

hence:

Solution for θ

${\displaystyle \therefore \ \ \theta =\pm \cos ^{-1}{\left({\frac {\beta }{\omega }}(\rho -\nu )\right)}}$

Taking the cosine of both sides, multiplying by omega over beta and reversing sides gives:

${\displaystyle \rho -\nu ={\frac {\omega }{\beta }}\cos \theta }$

${\displaystyle \rho =\nu +{\frac {\omega }{\beta }}\cos \theta }$

re-expressing in terms of r:

Solution for r

${\displaystyle r={\frac {r_{0}}{1+e\cos \theta }}}$

Where: ${\displaystyle r_{0}={\frac {\beta ^{2}}{\mu }};\ e={\frac {L}{m}}{\sqrt {{\frac {1}{\beta ^{4}}}+{\frac {2{\mathcal {H}}}{m\mu ^{2}}}}}}$

## Mathematics/Physics (Old)

Mathematics/Physics (Old)

Schrodinger's Equation for a Linear Potential in 1d
I have not found the following elsewhere on the internet which I have found fustrating before when I needed to know this or would have liked to have known this. So I thought out of 'do unto others, what you would like others to do to you' I better put it somewhere and where better than here.

If:
${\displaystyle {\hat {H}}=-{\frac {\hbar ^{2}}{2m}}{\frac {d^{2}}{dx^{2}}}+kx}$
Where ${\displaystyle {\hat {H}}}$ is the Hamiltonian operator then if working on the semi-infinite interval ${\displaystyle [0,\infty ]}$ the eigenfunctions (which in fact have been normalized) and eigenvalues are:
${\displaystyle E_{n}=-{\sqrt[{3}]{\frac {\hbar ^{2}k^{2}}{2m}}}\lambda _{n}}$
${\displaystyle \psi _{n}(x)={\sqrt[{6}]{\frac {18mk}{\hbar ^{2}}}}\Gamma \left({\frac {1}{3}}\right)\mathrm {Ai} \left({\sqrt[{3}]{\frac {2mk}{\hbar ^{2}}}}x+\lambda _{n}\right)}$
Where ${\displaystyle \lambda _{n}}$ are the roots of the airy function ${\displaystyle \mathrm {Ai} (x)}$

Schrodinger's Equation for a Spherically Symmetric Linear Potential
${\displaystyle {\hat {H}}=-{\frac {\hbar ^{2}}{2m}}{\frac {d^{2}}{dr^{2}}}+{\frac {\hbar ^{2}l(l+1)}{2mr^{2}}}+kr}$
${\displaystyle {\hat {H}}u_{nl}(r)=E_{nl}u_{nl}(r)}$
Perturbation theory yields using our solution in 1d with ${\displaystyle {\hat {H}}'={\frac {\hbar ^{2}l(l+1)}{2mr^{2}}}}$ as the perturbation to the unperturbed Hamiltonian ${\displaystyle {\hat {H}}_{0}=-{\frac {\hbar ^{2}}{2m}}{\frac {d^{2}}{dr^{2}}}+kr}$.
${\displaystyle u_{nl}(r)=\psi _{n}(r)+\sum _{m\neq n}{\frac {\langle {\psi _{m}}|{\hat {H}}'|\psi _{n}\rangle }{E_{n}^{(0)}-E_{m}^{(0)}}}\psi _{m}(r)}$
${\displaystyle u_{nl}(r)={\sqrt[{6}]{\frac {18mk}{\hbar ^{2}}}}\Gamma \left({\frac {1}{3}}\right)\mathrm {Ai} \left({\sqrt[{3}]{\frac {2mk}{\hbar ^{2}}}}r+\lambda _{n}\right)+3l(l+1){\sqrt[{6}]{\frac {\hbar ^{2}}{2mk}}}\left(\Gamma \left({\frac {1}{3}}\right)\right)^{3}\sum _{m\neq n}{\frac {\int _{0}^{\infty }{\frac {\mathrm {Ai} \left({\sqrt[{3}]{\frac {2mk}{\hbar ^{2}}}}\rho +\lambda _{n}\right)\mathrm {Ai} \left({\sqrt[{3}]{\frac {2mk}{\hbar ^{2}}}}\rho +\lambda _{m}\right)}{\rho ^{2}}}d\rho }{\lambda _{m}-\lambda _{n}}}\mathrm {Ai} \left({\sqrt[{3}]{\frac {2mk}{\hbar ^{2}}}}r+\lambda _{m}\right)}$
Which is first order accurate (in the perturbation) where ${\displaystyle \psi _{n}(r)}$ is the one dimensional wave function (from the above section) with the input argument of r instead of x and:
${\displaystyle E_{nl}=E_{n}^{(0)}+\langle {\psi _{n}}|{\hat {H}}'|\psi _{n}\rangle }$
Where ${\displaystyle E_{n}^{(0)}}$ is the energies of the unperturbed problem (that is the 1d problem with a linear potential).
${\displaystyle E_{nl}=-{\sqrt[{3}]{\frac {\hbar ^{2}k^{2}}{2m}}}\lambda _{n}+l(l+1){\sqrt[{3}]{\frac {9\hbar ^{2}}{4mk}}}\left(\Gamma \left({\frac {1}{3}}\right)\right)^{2}\int _{0}^{\infty }{\frac {\mathrm {Ai} \left({\sqrt[{3}]{\frac {2mk}{\hbar ^{2}}}}\rho +\lambda _{n}\right)\mathrm {Ai} \left({\sqrt[{3}]{\frac {2mk}{\hbar ^{2}}}}\rho +\lambda _{n}\right)}{\rho ^{2}}}d\rho }$
Using what's given above and the following one can construct the three dimensional wave function.
${\displaystyle \psi _{nlm}\left(r,\theta ,\phi \right)={\frac {u_{nl}(r)}{r}}Y_{lm}\left(\theta ,\phi \right)}$

Perturbation Theory for Nonlinear Differential Equations
Suppose:
${\displaystyle u_{xx}=F\left(\alpha ,x,u,u_{x}\right)}$
Where ${\displaystyle \alpha }$ is a parameter that can be varied from 0 to 1 where at ${\displaystyle \alpha =0}$ the solution is known and ${\displaystyle \alpha =1}$ is the value of alpha for which a solution is desired.
Subject to:
${\displaystyle u(a)=u_{a}}$
${\displaystyle u(b)=u_{b}}$
If ${\displaystyle u_{0}}$ denotes the solution for when ${\displaystyle \alpha =0}$ then we can expand ${\displaystyle u(x,\alpha )}$ as:
${\displaystyle u(x,\alpha )=u_{0}+\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)}}$

In turn we may substitute this into our orignal equation:
${\displaystyle \left(u_{0}+\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)}\right)_{xx}=F\left(\alpha ,x,u_{0}+\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)},(u_{0}+\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)})_{x}\right)}$
Here we use a derivative approximation to linearise the above equation
${\displaystyle (u_{0})_{xx}+\alpha \Delta _{xx}^{(1)}+\alpha ^{2}\Delta _{xx}^{(2)}+\sum _{n}\alpha ^{n}\Delta _{xx}^{(n)}=F_{0}+F_{0,u}\left(\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)}\right)+F_{0,u_{x}}\left(\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)}\right)_{x}}$
Where the zero index is to denote that it is evaluated with ${\displaystyle u=u_{0}}$ and the u and ${\displaystyle u_{x}}$ in the index indicates partial differention with respect to said variables. This leads to a series of differential equations in terms of the corrections (by equating the powers of alpha) and now we should point out that the boundary conditions on each of these differential equations are zero except for the zeroth order equation which is idenitcal to the equation for ${\displaystyle u_{0}}$. It should be noted however that in F we require that ${\displaystyle \alpha }$ should appear in some finite order polynomial for perturbation theory to work.
If the polynomial inside F in terms of alpha that appears is linear then the following should hold:
${\displaystyle (u_{0})_{xx}+\alpha \Delta _{xx}^{(1)}+\alpha ^{2}\Delta _{xx}^{(2)}+\sum _{n}\alpha ^{n}\Delta _{xx}^{(n)}=F_{0}+\alpha F_{0,\alpha }+(F_{0,u}+\alpha F_{0,\alpha u})\left(\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)}\right)+(F_{0,u_{x}}+\alpha F_{0,\alpha u_{x}})\left(\alpha \Delta ^{(1)}+\alpha ^{2}\Delta ^{(2)}+\sum _{n}\alpha ^{n}\Delta ^{(n)}\right)_{x}}$
Where in terms without alpha derivatives ${\displaystyle \alpha }$ is set to 0.
${\displaystyle \alpha ^{1}:}$ ${\displaystyle \Delta _{xx}^{(1)}-F_{0,u_{x}}\Delta _{x}^{(1)}-F_{0,u}\Delta ^{(1)}=F_{0,\alpha }}$
${\displaystyle \alpha ^{2}:}$${\displaystyle \Delta _{xx}^{(2)}-F_{0,u_{x}}\Delta _{x}^{(2)}-F_{0,u}\Delta ^{(2)}=F_{0,\alpha u}\Delta ^{(1)}+F_{0,\alpha u_{x}}\Delta _{x}^{(1)}}$
${\displaystyle \alpha ^{n}:}$ ${\displaystyle \Delta _{xx}^{(n)}-F_{0,u_{x}}\Delta _{x}^{(n)}-F_{0,u}\Delta ^{(n)}=F_{0,\alpha u}\Delta ^{(n-1)}+F_{0,\alpha u_{x}}\Delta _{x}^{(n-1)}}$
1D PDE similar to the Wave Equation
${\displaystyle {\frac {\partial ^{2}u}{\partial t^{2}}}={\frac {\partial ^{2}u}{\partial x^{2}}}-kxu}$
${\displaystyle u(0,t)=u(\infty ,t)=0}$
${\displaystyle u(x,0)=f(x)}$ such that ${\displaystyle f(0)=f(\infty )=0}$
${\displaystyle {\dot {u}}(x,0)=g(x)}$ such that ${\displaystyle g(0)=g(\infty )=0}$
${\displaystyle u(x,t)=\sum _{n=1}^{\infty }a_{n}X_{n}(x)T_{n}(t)}$
Where:
${\displaystyle {\frac {d^{2}X_{n}}{dx^{2}}}-kxX_{n}={\tilde {\lambda _{n}}}X_{n}}$
${\displaystyle X_{n}(x)={\sqrt[{6}]{\frac {9}{k}}}\Gamma \left({\frac {1}{3}}\right)\mathrm {Ai} \left({\sqrt[{3}]{k}}x+\lambda _{n}\right)}$
Where ${\displaystyle \lambda _{n}'s}$ are the zeros of the airy ${\displaystyle \mathrm {Ai} (x)}$ function and ${\displaystyle {\tilde {\lambda }}_{n}=k^{-1/3}\lambda _{n}}$
${\displaystyle T_{n}(t)=a_{n}\sin \left({\sqrt {-k^{2/3}\lambda _{n}}}t\right)+b_{n}\cos \left({\sqrt {-k^{2/3}\lambda _{n}}}t\right)}$
From the two initial conditions stated earlier we can deduce that the coefficients ${\displaystyle a_{n}}$ and ${\displaystyle b_{n}}$ are respectively:
${\displaystyle a_{n}={\frac {\sqrt[{3}]{3}}{\sqrt {-k\lambda _{n}}}}\Gamma \left({\frac {1}{3}}\right)\int _{0}^{\infty }g(\xi )\mathrm {Ai} \left({\sqrt[{3}]{k}}\xi +\lambda _{n}\right)d\xi }$
${\displaystyle b_{n}={\sqrt[{6}]{\frac {9}{k}}}\Gamma \left({\frac {1}{3}}\right)\int _{0}^{\infty }f(\xi )\mathrm {Ai} \left({\sqrt[{3}]{k}}\xi +\lambda _{n}\right)d\xi }$
2D Sturm-Liouville Problem of the form of the 2D Simple Harmonic Oscillator problem from quantum mechanics
MATLAB code and figures for solving/viewing the solutions of the problem:
${\displaystyle \left({\frac {\partial ^{2}}{\partial x^{2}}}+{\frac {\partial ^{2}}{\partial y^{2}}}-k(x^{2}+y^{2})\right)u_{nl}=\lambda _{n}u_{nl}}$
With k set to one the following MATLAB code may be constructed and executed to give the following graphs and eigenvalues.

clear all
N=50; NN=90;

k=1;
%Truncated domain method is being used to Solve the above problem the computational domain [-inf,inf] is

%being truncated to [-L,L]
L=6; a=-L; b=L;

%T_mn =T_n(x_m) where T_n(x) denotes the Chebyshev Poly. of the second kind with the input argument of the

%extrema of T_N (x) on the interval [-1,1],  D1 is the first order chebyshev differentiation matrix

%transformed to the domain [a,b], D2 is just the 2nd order variant of D1, E1 and E2 are D1 and D2

%respectively with the first and last rows and columns removed. x is the chebyshev extrema points mapped
%onto the domain [a,b]. xsub is x with endpoints removed.

%[T D1 D2 E1 E2 x xsub]=cheb(N,a,b); %(function code given below)

%Linearly spaced points xc are used at the end to improve the resolution of the solution.
xc=linspace(-1,1,NN+1)'; TT=cos(acos(xc)*(0:N));
%Solving the above problem and ordering the eigenvalues from biggest (in this case least negative) to smallest (or most negative)
I=eye(N-1); [xx yy]=meshgrid(xsub,xsub); X=diag(xx(:)); Y=diag(yy(:));
H=kron(E2,I)+kron(I,E2)-k*(X.^2+Y.^2);
[uu lam]=eig(H);
lam=diag(lam); [lam IX]=sort(real(lam),'descend');
u=zeros(N+1,N+1,(N-1)^2); uc=zeros(NN+1,NN+1,(N-1)^2);
uuc=zeros((NN+1)^2,(N-1)^2);
uue=zeros((N+1)^2,(N-1)^2);
for i=1:(N-1)^2
u(2:N,2:N,i)=reshape(uu(:,IX(i)),N-1,N-1); u(1:N+1,1:N+1,i)=[zeros(1,N+1); zeros(N-1,1) u(2:N,2:N,i) zeros(N-1,1); zeros(1,N+1)];

end
%2d fast chebyshev transform used to determine the chebyshev series expansion coefficients. (code given below)
a=fct2d(u);

clear uu
%Getting the solution onto the equally spaced points xc
uuc=(kron(TT,TT))*a;
uu=reshape(uuc,(NN+1),NN+1,(N-1)^2);

[xx yy]=meshgrid(x,x); xc=L*linspace(-1,1,NN+1)';
[xxc yyc]=meshgrid(xc,xc);


function [T,D,D2,E1,E2,x,xsub] = cheb(N,a,b)
if N==0, D=0; x=1; return, end
x=-cos(pi*(0:N)/N)'; xsub=x(2:N); T=cos(acos(x)*(0:N));
%This part was borrowed from Nick Trevethan's book Spectral Methods in MATLAB (2001)
c=[2; ones(N-1,1); 2].*(-1).^(0:N)';
X=repmat(x,1,N+1);
dX=X-X';
D=(c*(1./c)')./(dX+eye(N+1));
D=D-diag(sum(D'));
%------end of section borrowed--------
D=2/(b-a)*D;
E1=D(2:N,2:N);
D2=D^2;
E2=D2(2:N,2:N);
x=(b-a)/2*x+(a+b)/2; xsub=(b-a)/2*xsub+(a+b)/2;
end


function a=fct2d(u)
[N , M, L]=size(u);

for i=1:L
ak=fct(fct(u(:,:,i))'); %fct and ifct's files are shown below
a(:,i)=ak(:);
end

end


function u=ifct2d(a)
[N2 L]=size(a);
N=sqrt(N2);
%it is assumed that the a is in the form of a N^2xL object
a=reshape(a,N,N,L);
%preallocating for speed

u=zeros(N,N,L);
for i=1:L
u(:,:,i)=ifct(ifct(a(:,:,i))');

end

end


function a=fct(f,l)
%Input of l=1 gives the Fast chebyshev transform at the points
%x=-cos(pi/N*((0:N-1)'+1/2)); if doesn't equal this value it is at the
%points x=-cos(pi/N*0:N);
if ~exist('l','var')
l=0;
end
f=f(end:-1:1,:);
A=size(f); N=A(1);
if exist('A(3)','var') && A(3)~=1
for i=1:A(3)
if l==1
a(:,:,i)=sqrt(2/N)*dct(f(:,:,i));
a(1,:,i)=a(1,:,i)/sqrt(2);
else
F=ifft([f(1:N,:,i);f(N-1:-1:2,:,i)]);
a(:,:,i)=([F(1,:); 2*F(2:(N-1),:); F(N,:)]); %This code and the code below that is the function

%ifct is in part derived from a file on MATLAB file exchange by Greg von Winckel (although not in its entirety)
end
end
else
if l==1
a=sqrt(2/N)*dct(f(:,:,i));
a(1,:)=a(1,:)/sqrt(2);
else
F=ifft([f(1:N,:);f(N-1:-1:2,:)]);
a=([F(1,:); 2*F(2:(N-1),:); F(N,:)]);
end
a=real(a);
end


function f=ifct(a,l)
%l=1 x=-cos(pi/N*((0:N-1)'+1/2)) otherwise x=-cos(pi/N*(0:N)')
k=size(a); N=k(1);
if ~exist('l','var')
l=0;
end

if l==1

f=idct(sqrt(N/2)*[a(1,:)*sqrt(2); a(2:end,:)]);

else
A=a;
F=fft([A(1,:); [A(2:N,:);A(N-1:-1:2,:)]/2]);

B=(F(1:N,:));
f=B;
end
f=real(f(N:-1:1,:));

end


(Not sure If I'm required to do this but just in case there's any legal issues with omitting this I'm gonna place it in this page)

Redistribution and use in source and binary forms, with or without modification, are permitted provided that the following conditions are met:

   * Redistributions of source code must retain the above copyright
notice, this list of conditions and the following disclaimer.
* Redistributions in binary form must reproduce the above copyright
notice, this list of conditions and the following disclaimer in
the documentation and/or other materials provided with the distribution



THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

1st eigenfunction of the above MATLAB Code
For this eigenfunction the corresponding eigenvalue is: ${\displaystyle \lambda _{1}\approx -2}$
2nd eigenfunction of the above MATLAB Code
${\displaystyle \lambda _{2}\approx -4}$
3rd eigenfunction of the above MATLAB Code
${\displaystyle \lambda _{3}\approx -4}$ (Note this is the same as the 2nd eigenvalue, because as indicated by the only 1 subscript for the eigenvalues and two for the eigenfunctions this problem is degenerate.)

4th eigenfunction of the above MATLAB Code
${\displaystyle \lambda _{4}\approx -6}$
5th eigenfunction of the above MATLAB Code
${\displaystyle \lambda _{5}\approx -6}$
6th eigenfunction of the above MATLAB Code
${\displaystyle \lambda _{6}\approx -6}$

FEM and Domain Decomposition Methods
${\displaystyle {\frac {d}{dx}}\left(p(x){\frac {du}{dx}}\right)+q(x)u=r(x)}$
${\displaystyle u(a)=\alpha ,u(b)=\beta }$
For this problem the following MATLAB code may be constructed (This code uses the finite element method with linear shape functions):

function [x u]=FEMH(p,q,rd,a,b,alpha,beta,N)
%d/dx(p(x) du/dx)+q(x)u=r(x), u(a)=alpha; u(b)=beta

x=linspace(a,b,N+1)';
function L=q1f(x)
xi=(x-x(1))/(x(end)-x(1));
H1=(1-xi);
L=q(x).*H1.^2;
end
function l=pp(x)
l=p(x);
end
function L=q2f(x)
xi=(x-x(1))/(x(end)-x(1));
H2=xi;
L=q(x).*H2.^2;
end
function L=q3f(x)
xi=(x-x(1))/(x(end)-x(1));
H1=1-xi; H2=xi;
L=q(x).*H1.*H2;
end
function L=r1f(x)
xi=(x-x(1))/(x(end)-x(1));
H1=1-xi;
[~, dl]=p(x);
r=rd(x)-(beta-alpha)/(b-a)*(dl+x-a)+alpha;
L=r.*H1;
end
function L=r2f(x)
xi=(x-x(1))/(x(end)-x(1));
H2=xi;
L=r(x).*H2;
end
p1=zeros(N,1); q1=zeros(N,1); q2=zeros(N,1); q3=zeros(N,1); r1=zeros(N,1); r2=zeros(N,1); F=zeros(N-1,1);
for i=1:N
if i~=N
F(i)=-(r1(i)+r2(i));
end
end
p11=p1(2:N);
p1=p1(1:N-1); q2=q2(1:N-1);
q11=q1(2:N);
q31=q3(2:N);

K=diag(p1+p11-q11-q2);

K=K+diag(q31(1:N-2)-p11(1:N-2),1)+diag(q31(1:N-2)-p11(1:N-2),-1);

uu=K\F;
v=[0; uu; 0];
[~, dl]=p(x);

u=v+(beta-alpha)/(b-a)*(dl+x-a)+alpha;
end

function [x u]=SubDomCheb(N,M,G,bd,A)
%This function solves the problem:
%d/dx (p(x) du/dx)+q(x)u=r(x)
%Where the function G is defined such that:
%[p q r]=G(x,A);
%alpha1*u(a)+alpha2*u'(a)=alpha3, beta1*u(b)+beta2*u'(b)=beta3;
%using domain decomposition method with chebyshev cardinal functions.

[T, D1]=cheb(N,-1,1);
x=-cos(pi*(0:N)'/N);
a=bd(1); alpha1=bd(2); alpha2=bd(3); alpha3=bd(4); b=bd(5); beta1=bd(6); beta2=bd(7); beta3=bd(8);

D1=2*M/(b-a)*D1;
xx=zeros(N+1,M);
for i=1:M
xx(:,i)=(b-a)/(2*M)*(x+1)+(b-a)/M*(i-1)+a;
xt((N+1)*(i-1)+1:i*(N+1),1)=xx(:,i);
end
[p, q, r]=G(xt,A);
F=r;
clear p q

for i=1:M
if i==1
clear H
[p q]=G(xx(:,i),A);
H=D1*diag(p)*D1+diag(q);
H(1,1:N+1)=alpha1*[1 zeros(1,N)]+alpha2*D1(1,:); H(N+1,1:N+1)=D1(N+1,:);
H(N+1,(N+2):2*(N+1))=-D1(1,:);
K(1:N+1,1:2*(N+1))=H;
F(N+1,1)=0; F(1)=alpha3;
elseif i==M
clear H
[p q]=G(xx(:,i),A);
H(:,(N+2):2*(N+1))=D1*diag(p)*D1+diag(q);
H(1,1:2*(N+1))=[zeros(1,N) 1 -1 zeros(1,N)];
H(N+1,(N+2):2*(N+1))=beta1*[zeros(1,N) 1]+beta2*D1(N+1,:);
K((i-1)*(N+1)+1:i*(N+1),(i-2)*(N+1)+1:i*(N+1))=H;
F((i-1)*(N+1)+1)=0; F(i*(N+1))=beta3;
else
clear H
[p q]=G(xx(:,i),A);
H(1:(N+1),(N+2):2*(N+1))=D1*diag(p)*D1+diag(q);
H(1,1:2*(N+1))=[zeros(1,N) 1 -1 zeros(1,N)];
H((N+1),(N+2):3*(N+1))=[D1(N+1,:) -D1(1,:)];
K(((i-1)*(N+1)+1):(i*(N+1)),((i-2)*(N+1)+1):((i+1)*(N+1)))=H;
F((i-1)*(N+1)+1)=0; F(i*(N+1))=0;
end
end

uu=K\F;
xx=linspace(-1,1,N+1)'; TT=cos(acos(xx)*(0:N));
for i=1:M
aa(:,i)=fct(uu((i-1)*(N+1)+1:i*(N+1)));
us(:,i)=TT*aa(:,i);
u((i-1)*(N+1)+1:i*(N+1),1)=us(:,i);
xs(:,i)=(b-a)/(2*M)*(xx+1)+(b-a)/M*(i-1)+a;
x((i-1)*(N+1)+1:i*(N+1),1)=xs(:,i);
end
end


PDEs
${\displaystyle {\frac {\partial u}{\partial t}}={\hat {L}}u+f(x,t)u+g(x,t)}$
${\displaystyle u(x,0)=u_{0}}$
And Sturm-Liouville problem boundary conditions with respect to the x coordinate.
Where ${\displaystyle {\hat {L}}}$ is a Sturm-Liouville operator. That is it satisfies:
${\displaystyle {\hat {L}}\phi _{n}=\lambda _{n}\phi _{n}}$
Subject to standard SL boundary conditions. And of course the orthogonality condition, however for convenience an additional normality condition will be imposed on the norms of each eigenfunction, ${\displaystyle \phi _{n}}$.
${\displaystyle (\phi _{m},\phi _{n})=\delta _{m,n}}$
${\displaystyle u(x,t)=\sum _{n=0}^{\infty }\phi _{n}(x)\left[A_{n}+\int _{0}^{t}v(\tau )\exp \left(-\lambda _{n}\tau -\int _{0}^{\tau }w(\xi )d\xi \right)d\tau \right]\exp \left(\lambda _{n}t+\int _{0}^{t}w(\tau )d\tau \right)}$

${\displaystyle A_{n}=(u_{0},\phi _{n})}$
${\displaystyle v_{n}(\tau )=(g(x,\tau ),\phi _{n}(x))}$
${\displaystyle w_{n}(\tau )=(f(x,\tau ),\phi _{n}(x)^{2})}$

SLE
${\displaystyle -{\frac {d^{2}y}{dx^{2}}}+xy=\lambda y}$

the solution is:
${\displaystyle y(x)=a\mathrm {Ai} \left(x-\lambda \right)}$

## Reference list

1. ^ a b c Taylor, JR (2005). "Chapter 2: Projectiles and Charged Particles". Classical Mechanics (PDF)|format= requires |url= (help). Sausalito, USA: University Science Books. ISBN 978-1891389221.
2. ^ Mohr, PJ; Taylor, BN; Newell, DB (2011). Baker, J; Douma, M; Kotochigova, S (ed.). "The 2010 CODATA Recommended Values of the Fundamental Physical Constants" (Web Version 6.0)". Gaithersburg, MD: National Institute of Standards and Technology.CS1 maint: multiple names: authors list (link)