Diffpack 


IV3 . Examples and applications 
The Diffpack libraries have been successfully used in several applications involving numerical solution of differential equations. Most of the examples mentioned below require only a few pages of C++ code when Diffpack is utilized. The main part of the code deals with details of the numerical scheme used to solve the differential equations, while user interfaces and visualization are limited to a few lines of code.
 
Contributed by: Hans Petter Langtangen  
 
Primitive simulators for the standard model PDEs such as the Laplace, Poisson, diffusion, heat and Helmholtz equations. Such simulators are created in the introductory report on finite element programming in Diffpack. Figure: The temperature distribution in a thickwalled tube with fixed temperature values at the inner and outer boundary. Axisymmetric problem solved in Cartesian coordinates. 
Contributed by: Hans Petter Langtangen  
 
An efficient finite element solver for the standard, linear wave equation in a general 1D/2D/3D geometry. Figure: The amplitude of 3D sound waves in a box.

Contributed by: Hans Petter Langtangen and Geir Pedersen  
 
A finite element solver for weakly dispersive and nonlinear water waves described by a set of coupled, nonlinear PDEs in 2D (Boussinesq equations). Figure: The water surface elevation due to an incoming wave over a sea mountain. 
Contributed by: Hans Petter Langtangen  
 
A finite element solver for isotropic, linear elasticity (2D plain strain and 3D). Figure: The von Mises yield stress in an elastic body subject to external forces. 
Contributed by: Glenn Terje Lines  
 
Diffpack has been used for numerical simulation of the excitation process in the human heart to find better quantitative measurement methods for myocardial infarction and ischemia. The simulator solves an equation system consisting of a reactiondiffusion parabolic differential equation and an elliptic equation governing the potential distribution in the cardiac muscle and surrounding tissues. Click for movie! (711K) Figure: The potential distribution in the cardiac muscle at a specific time level. 