2.6.2 Boundary value problem for the Black Scholes equation

problem number 97

From Mathematica DSolve help pages.

Solve for \(V(t,s)\) \[ \frac {\partial v}{\partial t} + \frac {1}{2} \sigma ^2 s^2 \frac {\partial ^2 v}{\partial s^2} +(r-q) s \frac {\partial v}{\partial s} - r v(t,s)=0 \] With boundary condition \( v(T,s) = \psi (s)\)

Reference https://en.wikipedia.org/wiki/Black%E2%80%93Scholes_equation

Mathematica


\[\left \{\left \{v(t,s)\to \frac {e^{r (t-T)} \int _{-\infty }^{\infty } \psi \left (e^{K[1]}\right ) \exp \left (-\frac {\left (-K[1]+\frac {1}{2} (t-T) \left (2 q-2 r+\sigma ^2\right )+\log (s)\right )^2}{2 \sigma ^2 (T-t)}\right ) \, dK[1]}{\sqrt {2 \pi } \sqrt {\sigma ^2 (T-t)}}\right \}\right \}\]

Maple


\[v \left (t , s\right ) = \]