learn-physics-0.6.0.0: Haskell code for learning physics

Physics.Learn.Ket

Description

This module contains ket vectors, bra vectors, and operators for quantum mechanics.

Synopsis

# Documentation

data Ket Source

A ket vector describes the state of a quantum system.

Instances

 Source Source Source Source Source Source Source Source Source Source

data Bra Source

A bra vector describes the state of a quantum system.

Instances

 Source Source Source Source Source Source Source Source Source Source

data Operator Source

An operator describes an observable (a Hermitian operator) or an action (a unitary operator).

class Mult a b c | a b -> c where Source

Generic multiplication including inner product, outer product, operator product, and whatever else makes sense. No conjugation takes place in this operation.

Methods

(<>) :: a -> b -> c infixl 7 Source

Instances

 Source Source Source Source Source Source Source Source Source Source Source Source

class Dagger a b | a -> b where Source

The adjoint operation on complex numbers, kets, bras, and operators.

Methods

dagger :: a -> b Source

Instances

 Source Source Source Source

class Representable a b | a -> b where Source

Methods

rep :: OrthonormalBasis -> a -> b Source

dim :: a -> Int Source

Instances

 Source Source Source

An orthonormal basis of kets.

Instances

 Source

makeOB :: [Ket] -> OrthonormalBasis Source

Make an orthonormal basis from a list of linearly independent kets.

State of a spin-1/2 particle if measurement in the x-direction would give angular momentum +hbar/2.

State of a spin-1/2 particle if measurement in the x-direction would give angular momentum -hbar/2.

State of a spin-1/2 particle if measurement in the y-direction would give angular momentum +hbar/2.

State of a spin-1/2 particle if measurement in the y-direction would give angular momentum -hbar/2.

State of a spin-1/2 particle if measurement in the z-direction would give angular momentum +hbar/2.

State of a spin-1/2 particle if measurement in the z-direction would give angular momentum -hbar/2.

np :: Double -> Double -> Ket Source

State of a spin-1/2 particle if measurement in the n-direction, described by spherical polar angle theta and azimuthal angle phi, would give angular momentum +hbar/2.

nm :: Double -> Double -> Ket Source

State of a spin-1/2 particle if measurement in the n-direction, described by spherical polar angle theta and azimuthal angle phi, would give angular momentum -hbar/2.

The Pauli X operator.

The Pauli Y operator.

The Pauli Z operator.