learn-physics-0.6.6: Haskell code for learning physics
Copyright(c) Scott N. Walck 2016-2018
LicenseBSD3 (see LICENSE)
MaintainerScott N. Walck <walck@lvc.edu>
Stabilityexperimental
Safe HaskellTrustworthy
LanguageHaskell2010

Physics.Learn.BeamStack

Description

Splitters, recombiners, and detectors for Stern-Gerlach experiments.

Synopsis

Core laboratory components

data BeamStack Source #

Instances

Instances details
Show BeamStack Source # 
Instance details

Defined in Physics.Learn.BeamStack

randomBeam :: BeamStack Source #

A beam of randomly oriented spin-1/2 particles.

split :: Double -> Double -> BeamStack -> BeamStack Source #

Given angles describing the orientation of the splitter, removes an incoming beam from the stack and replaces it with two beams, a spin-up and a spin-down beam. The spin-down beam is the most recent beam on the stack.

recombine :: Double -> Double -> BeamStack -> BeamStack Source #

Given angles describing the orientation of the recombiner, returns a single beam from an incoming pair of beams.

applyBField :: Double -> Double -> Double -> BeamStack -> BeamStack Source #

Given angles describing the direction of a uniform magnetic field, and given an angle describing the product of the Larmor frequency and the time, return an output beam from an input beam.

dropBeam :: BeamStack -> BeamStack Source #

Remove the most recent beam from the stack.

flipBeams :: BeamStack -> BeamStack Source #

Interchange the two most recent beams on the stack.

numBeams :: BeamStack -> Int Source #

Return the number of beams in a BeamStack.

detect :: BeamStack -> [Double] Source #

Return the intensities of a stack of beams.

Standard splitters

splitX :: BeamStack -> BeamStack Source #

A Stern-Gerlach splitter in the x direction.

splitY :: BeamStack -> BeamStack Source #

A Stern-Gerlach splitter in the y direction.

splitZ :: BeamStack -> BeamStack Source #

A Stern-Gerlach splitter in the z direction.

Standard magnetic fields

applyBFieldX :: Double -> BeamStack -> BeamStack Source #

Given an angle in radians describing the product of the Larmor frequency and the time, apply a magnetic in the x direction to the most recent beam on the stack.

applyBFieldY :: Double -> BeamStack -> BeamStack Source #

Given an angle in radians describing the product of the Larmor frequency and the time, apply a magnetic in the y direction to the most recent beam on the stack.

applyBFieldZ :: Double -> BeamStack -> BeamStack Source #

Given an angle in radians describing the product of the Larmor frequency and the time, apply a magnetic in the z direction to the most recent beam on the stack.

Standard combiners

recombineX :: BeamStack -> BeamStack Source #

A Stern-Gerlach recombiner in the x direction.

recombineY :: BeamStack -> BeamStack Source #

A Stern-Gerlach recombiner in the y direction.

recombineZ :: BeamStack -> BeamStack Source #

A Stern-Gerlach recombiner in the z direction.

Filters

xpFilter :: BeamStack -> BeamStack Source #

Filter for spin-up particles in the x direction.

xmFilter :: BeamStack -> BeamStack Source #

Filter for spin-down particles in the x direction.

zpFilter :: BeamStack -> BeamStack Source #

Filter for spin-up particles in the z direction.

zmFilter :: BeamStack -> BeamStack Source #

Filter for spin-down particles in the z direction.