Nils Blümer - demonstration programs

Field lines

/* name of prog: field lines
   project:      demonstration for E-dynamics course
   author:       Nils Bluemer
   version:      1, 8.5.00
   interfaces:   input: parameters inside code
                 output: stdout

program takes positions of charges (+1, -1, or 0) and computes field
lines within some window (-(maxxy,maxy)..(maxxy,maxxy)). 

Note that the density of lines has an error of at least +/- 1 lines within 
some given area (e.g. double lines can appear due to symmetry when there
should only be one line). The shape of the lines is approximately correct,
however.

Possible improvements:   integration rule (higher order, midpoint)
                         input (preferably via WWW-interface)*/

Source: field_lines.c. Also needed (internal): nrutil.c

Plots of some output (click to enlarge):
field_lines_s.gif

Poisson equation

/* name of prog: Poisson equation
   project:      demonstration for E-dynamics course
   author:       Nils Bluemer
   version:      2, 26.5.00
   interfaces:   input: parameters inside code/compile parameters
                 output: stdout

   indizes in arrays go from 1 to nmax!
   coords go from 0 to size[i]

   NEW: multigrid

Possible improvements:  
   include open boundary conditions
   compute charge density on surface
   thin boundaries (thickness 1 instead dist) for dist>1 */
Source: poisson2.c. Also needed (internal): nrutil.c

Plots of some output (click to enlarge):
poisson_s.gif


Nils Blümer
Last modified: Fri Jul 21 14:22:26 MESZ 2000