Copyright | (c) Scott N. Walck 2023 |
---|---|
License | BSD3 (see LICENSE) |
Maintainer | Scott N. Walck <walck@lvc.edu> |
Stability | stable |
Safe Haskell | Safe-Inferred |
Language | Haskell2010 |
Code from chapter 20 of the book Learn Physics with Functional Programming
Documentation
twoSpringsForces :: [Force] Source #
kineticEnergy :: ParticleState -> R Source #
systemKE :: MultiParticleState -> R Source #
linearSpringPE :: R -> R -> ParticleState -> ParticleState -> R Source #
twoSpringsPE :: MultiParticleState -> R Source #
twoSpringsME :: MultiParticleState -> R Source #
billiardForces :: R -> [Force] Source #
ballRadius :: R Source #
billiardUpdate :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> R -> TimeStep -> MultiParticleState -> MultiParticleState Source #
billiardEvolver :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> R -> TimeStep -> MultiParticleState -> [MultiParticleState] Source #
billiardStates :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> R -> TimeStep -> [MultiParticleState] Source #
billiardStatesFinite :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> R -> TimeStep -> [MultiParticleState] Source #
momentum :: ParticleState -> Vec Source #
systemP :: MultiParticleState -> Vec Source #
percentChangePMag :: [MultiParticleState] -> R Source #
data Justification Source #
Instances
Show Justification Source # | |
Defined in LPFPCore.MOExamples showsPrec :: Int -> Justification -> ShowS # show :: Justification -> String # showList :: [Justification] -> ShowS # |
Table Justification [[a]] |
pTable :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> [R] -> [TimeStep] -> Table Float Source #
percentChangeKE :: [MultiParticleState] -> R Source #
keTable :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> [R] -> [TimeStep] -> Table Float Source #
contactSteps :: [MultiParticleState] -> Int Source #
inContact :: MultiParticleState -> Bool Source #
contactTable :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> [R] -> [TimeStep] -> Table Int Source #
closest :: [MultiParticleState] -> R Source #
separation :: MultiParticleState -> R Source #
closestTable :: (TimeStep -> NumericalMethod MultiParticleState DMultiParticleState) -> [R] -> [TimeStep] -> Table Float Source #
forcesString :: [Force] Source #
mpsPos :: MultiParticleState -> IO () Source #
mpsVel :: MultiParticleState -> IO () Source #
dissipation :: R -> R -> TwoBodyForce Source #