Copyright | (c) Scott N. Walck 2015-2016 |
---|---|

License | BSD3 (see LICENSE) |

Maintainer | Scott N. Walck <walck@lvc.edu> |

Stability | experimental |

Safe Haskell | Trustworthy |

Language | Haskell98 |

This module contains functions to solve the (time dependent) Schrodinger equation in one spatial dimension for a given potential function.

- freeV :: Double -> Double
- harmonicV :: Double -> Double -> Double
- squareWell :: Double -> Double -> Double -> Double
- doubleWell :: Double -> Double -> Double -> Double
- stepV :: Double -> Double -> Double
- wall :: Double -> Double -> Double -> Double -> Double
- harm :: Int -> Double -> C
- coherent :: Double -> Double -> Complex Double -> Double -> Complex Double
- gaussian :: Double -> Double -> Double -> Complex Double
- movingGaussian :: Double -> Double -> Double -> Double -> Complex Double
- stateVectorFromWavefunction :: R -> R -> Int -> (R -> C) -> Vector C
- hamiltonianMatrix :: R -> R -> Int -> R -> R -> (R -> R) -> Matrix C
- expectX :: Vector C -> Vector R -> R
- picture :: (Double, Double) -> [Double] -> Vector C -> Picture

# Potentials

Free potential. The potential energy is zero everywhere.

Harmonic potential. This is the potential energy of a linear spring.

Finite square well potential. Potential is zero inside the well, and constant outside the well. Well is centered at the origin.

:: Double | width (for both wells and well separation) |

-> Double | energy height of barrier between wells |

-> Double | position |

-> Double | potential energy |

A double well potential. Potential energy is a quartic function of position that gives two wells, each approximately harmonic at the bottom of the well.

:: Double | energy height of barrier (to the right of origin) |

-> Double | position |

-> Double | potential energy |

A step barrier potential. Potential is zero to left of origin.

:: Double | thickness of wall |

-> Double | energy height of barrier |

-> Double | position of center of barrier |

-> Double | position |

-> Double | potential energy |

A potential barrier with thickness and height.

# Initial wavefunctions

:: Int | nonnegative integer n identifying stationary state |

-> Double | x |

-> C | complex amplitude |

Harmonic oscillator stationary state

# Utilities

stateVectorFromWavefunction Source

:: R | lowest x |

-> R | highest x |

-> Int | dimension of state vector |

-> (R -> C) | wavefunction |

-> Vector C | state vector |

Transform a wavefunction into a state vector.