learn-physics-0.6.4: Haskell code for learning physics

Physics.Learn.Charge

Description

This module contains functions for working with charge, electric field, electric flux, and electric potential.

Synopsis

# Charge

type Charge = Double Source #

Electric charge, in units of Coulombs (C)

A charge distribution is a point charge, a line charge, a surface charge, a volume charge, or a combination of these. The ScalarField describes a linear charge density, a surface charge density, or a volume charge density.

Constructors

 PointCharge Charge Position point charge LineCharge ScalarField Curve ScalarField is linear charge density (C/m) SurfaceCharge ScalarField Surface ScalarField is surface charge density (C/m^2) VolumeCharge ScalarField Volume ScalarField is volume charge density (C/m^3) MultipleCharges [ChargeDistribution] combination of charge distributions

Total charge (in C) of a charge distribution.

# Electric Field

The electric field produced by a charge distribution. This is the simplest way to find the electric field, because it works for any charge distribution (point, line, surface, volume, or combination).

Arguments

 :: Charge charge (in Coulombs) -> Position of point charge -> VectorField electric field (in V/m)

Electric field produced by a point charge. The function eField calls this function to evaluate the electric field produced by a point charge.

Arguments

 :: ScalarField linear charge density lambda -> Curve geometry of the line charge -> VectorField electric field (in V/m)

Electric field produced by a line charge. The function eField calls this function to evaluate the electric field produced by a line charge.

Arguments

 :: ScalarField surface charge density sigma -> Surface geometry of the surface charge -> VectorField electric field (in V/m)

Electric field produced by a surface charge. The function eField calls this function to evaluate the electric field produced by a surface charge.

Arguments

 :: ScalarField volume charge density rho -> Volume geometry of the volume charge -> VectorField electric field (in V/m)

Electric field produced by a volume charge. The function eField calls this function to evaluate the electric field produced by a volume charge.

# Electric Flux

The electric flux through a surface produced by a charge distribution.

# Electric Potential

Arguments

 :: Position position where electric potential is zero -> VectorField electric field -> ScalarField electric potential

Electric potential from electric field, given a position to be the zero of electric potential.

Electric potential produced by a charge distribution. The position where the electric potential is zero is taken to be infinity.