
Exercise
1: Newton Cooling Download the program cooling.m and run it with Matlab. Analyse the
code and the various finitedifference approximations used. Change the
time increment dt and describe the behavior of the different solutions.
Refer to the lecture
slides for details.

Exercise
2: The seismometer equation Download the program seismometer.m and run it with Matlab. The
program is a solution to the forced and damped oscillator descriptive
of a simple mechanical seismometer system. Play around with the forcing
frequency of the ground motion and the damping constant to investigate
the response of the seismometer (red) to the ground motion input
(blue). Refer to exercises.

Exercise
3: An ocean gyre Download the program gyre1d.m
and
run it with Matlab (you also need the program csh.m).
The program is a 1D solution to the
diffusionreactionadvection equation that may describe the behavior of
tracers (e.g., isotopes) in the oceans (compare with the exercises). Uncomment some of the other
possible solutions and investigate the numerical solutions.

Exercise
4: Acoustic wave propagation Download
the Matlab Program ac2d.m . Open
Matlab in a Command Window . Try
to run the model by typing >> ac2d in the working
directory

Exercise
5: Relaxation vs. timedependent solution (advanced) We
want to investigate what approach is more appropriate to run a
diffusion problem into a stationary state. The timedependent diffusion
equation is given as:
k is diffusivity, C
and p are space and timedependent functions. In the stationary
state d/dt(C)=0, so
a) Find an appropriate finitedifference scheme to solve the timedependent problem and write a Matlab program b)
Develop an appropriate relaxation scheme for the stationary problem. Compare the solutions for k=30km2/a (a1 Jahr). Space is defined between [0, 100km]. P ist a source function, set p=1 at x=50km, 0 else(this could be a constant temperature or concentration). Use 100 grid points in x. Find an appropriate time step for the timedependent solution and let it run into a stationary state. Compare with the analytical solution and the solution using the relaxation algorithm. 
Exercise
6: Finite differences vs. finite elements We
want to compare the numerical solutions of the acoustic wave equation
using finite differences and finite elements. Download the program femfd.m and the circular shift function csh.m and run it (>> femfd). Inspect the source
code and appreciate the entirely different approach to solving
the acoustic wave equation (by matrix inversion in the FEM case
and by differencing in the FD case). We want to demonstrate the
flexibility of the FEM approach by modifying the regular grid
spacing. Options are (1) to add a random perturbation to the regular
grid spacing, (2) to make a sinusoidal perturbation of the grid
spacing, (3) Gaussian perturbation, (4) Chebyshev collocation points.
Implement one or several of those perturbations and investigate the
influence on the solution.
