-
Notifications
You must be signed in to change notification settings - Fork 9
Expand file tree
/
Copy pathREADME
More file actions
93 lines (63 loc) · 3.24 KB
/
README
File metadata and controls
93 lines (63 loc) · 3.24 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
Harvard Applied Math 225: Code examples
=======================================
Harvard AM225 is a graduate course in scientific computing that covers a
variety of advanced topics in numerical analysis, algorithm design, and
high-performance computing. This course was developed by Chris H. Rycroft
and taught at Harvard during the Spring 2018, 2020, and 2021 semesters.
The main website is now located here:
https://people.math.wisc.edu/~chr/am225
This Git repository contains example codes from the course. The codes are
primarily written in C++ using the OpenMP library for multithreading. Some
additional programs in Python are provided.
Compiling
=========
The programs make use of the GNU Make utility for automatic building. Each
directory contains a "Makefile", which contains the compilation rules for
each program.
Each directory looks for a common configuration file called "config.mk" in the
top level of the repository, which sets the compiler name and various compiler
options.
To begin, you must create a "config.mk" file from one of the templates
provided in the "config" directory. The simplest method is to create a symlink
(shortcut) from one of the templates. On a Linux system, this can be done by
typing:
ln -s config/config.mk.linux config.mk
On a Mac system using GCC 12 installed with MacPorts (www.macports.org), use
the following:
ln -s config/config.mk.mac_mp config.mk
On a Mac system using GCC 12 installed with Homebrew (https://brew.sh), use
the following:
ln -s config/config.mk.mac_hb config.mk
For a custom configuration, copy one of the files from the "config" directory
into the root directory, and then manually edit it.
Once the "config.mk" file is created, change into one of the project
directories and type "make" to compile everything.
Organization
============
The course is divided into six units:
- Unit 0: Introduction and multithreaded programming
- Unit 1: Advanced ODE integration methods and theory
- Unit 2: Advanced numerical linear algebra
- Unit 3: Finite element methods
- Unit 4: Finite volume methods
- Unit 5: Special topics in scientific computing
Each Unit has several different directories with programs within them:
0a_root_finding - Introductory root finding examples
0b_cpp+openmp - C++ and OpenMP examples
1a_ode_solvers - A variety of ODE solvers (RK4, Euler, Ralston, etc.)
1b_extrap+do - Dense output examples and extrapolation solvers
1c_dop853 - The eighth-order Dormand-Prince DOP853 integrator
1d_symplectic - Symplectic integration examples
2a_linking - Small example of linking to precompiled binary object files.
2b_lapack+krylov - Examples using BLAS, LAPACK. Krylov methods applied to a
radial basis function test case.
2c_fft+ddecomp - Fast Fourier Transform and domain decomposition examples
3a_f_element - Finite element examples
4a_f_volume - Finite volume examples. Comparison to finite difference methods.
4b_traffic - Example programs to simulate the traffic equation, a nonlinear
hyperbolic conservation law
5a_fluid_sim - Simulation of incompressible fluids using Chorin's projection
method
5b_lsm_fmm - Level set method and the fast marching method examples
tgmg - An prototype 2D templated multigrid library developed by the Rycroft
group, which is required by the incompressible fluid simulation