# Computational Physics 1 (Fundamental Numerical Methods)

## Module PH2057

This module handbook serves to describe contents, learning outcome, methods and examination type as well as linking to current dates for courses and module examination in the respective sections.

### Module version of WS 2019/20 (current)

There are historic module descriptions of this module. A module description is valid until replaced by a newer one.

available module versions | |||
---|---|---|---|

WS 2019/20 | WS 2018/9 | WS 2017/8 | WS 2010/1 |

### Basic Information

PH2057 is a semester module in English language at Master’s level which is offered in winter semester.

This Module is included in the following catalogues within the study programs in physics.

- Specific catalogue of special courses for condensed matter physics
- Specific catalogue of special courses for nuclear, particle, and astrophysics
- Specific catalogue of special courses for Applied and Engineering Physics
- Complementary catalogue of special courses for Biophysics
- Specialization Modules in Elite-Master Program Theoretical and Mathematical Physics (TMP)

If not stated otherwise for export to a non-physics program the student workload is given in the following table.

Total workload | Contact hours | Credits (ECTS) |
---|---|---|

150 h | 60 h | 5 CP |

Responsible coordinator of the module PH2057 is Stefan Recksiegel.

### Content, Learning Outcome and Preconditions

#### Content

1. Introduction

‒ Numbers on computers

‒ Sources of errors

2. Integration

‒ Riemann definition

‒ Trapezoid rule, Simpson rule

‒ Gauss integration

‒ Adaptive stepsize

3. Differentiation

‒ Forward Difference, Central Difference

‒ Higher Orders

4. Root Finding

‒ Bisection

‒ Newton-Raphson

5. Linear Algebra

‒ Gauss elimination with back-substitution

‒ LU-Decomposition

‒ Singular Value Decomposition

6. Multidimensional Newton-Raphson

7. Data fitting / Inter-/Extrapolation

‒ Lagrange interpolation, Splines

‒ Least squares fit

‒ Linear least squares, non-linear chi^2

8. Ordinary Differendial Equations

‒ Classification of DEs

‒ Euler algorithm

‒ Midpoint algorithm

‒ Runge-Kutta

‒ Applications: Planetary motion, etc.

‒ Initial/boundary value problems

‒ ODE eigenvalues

9. Partial Differential Equations

‒ Elliptic PDEs

‒ Parabolic PDEs

‒ Hyperbolic PDEs

#### Learning Outcome

After successful completion of this module, students are able to

- understand and implement (in various programming languages) basic numerical methods such as integration, (multidimensional) root finding, data interpolation and fitting.
- classify and numerically solve all ordinary and simple partial differential equations.
- construct a proper DE description for a given physical problem.

#### Preconditions

No preconditions in addition to the requirements for the Master’s program in Physics.

### Courses, Learning and Teaching Methods and Literature

#### Courses and Schedule

Type | SWS | Title | Lecturer(s) | Dates |
---|---|---|---|---|

VO | 2 | Computational physics 1 | Recksiegel, S. |
Tue, 14:00–16:00, PH HS3 |

VO | 2 | Introduction to Programming | Recksiegel, S. |
Thu, 15:30–17:30, PH 1161 |

UE | 2 | Exercise to Computational Physics 1 | Recksiegel, S. | dates in groups |

#### Learning and Teaching Methods

This module consists of a lecture and an exercise class.

In the lecture, the contents are first explained on a theoretical level on an electronic whiteboard (the slides can be downloaded from the lecturer's web site immediately after the lectures). Then, the algorithms are implemented in the computer algebra system Mathematica to study the practical applicability of the concept. Whenever possible, the students are asked for input during this process, and if a suggested approach fails (e.g. due to numerical instabilities), the causes are discussed and alternatives are presented.

Exercise sheets (which frequently include reproduction of the results of the lecture) are first worked on individually by the students and then discussed in small groups (exercises) under supervision.

Students are invited to a guided tour to the Leibniz Supercomputing Centre (LRZ). Additionally an introduction to programming is offered. This lecture is directed especially and especially recommended to students without programming experience.

#### Media

Presentations on an electronic Whiteboard, demonstrations in Mathematica, C and Python ; exercise sheets. Accompanying web page: http://users.ph.tum.de/srecksie/lehre

#### Literature

- R.H. Landau, M.J. Páez and C.C. Bordeianu:
*Computational Physics: Problem Solving with Computers*, Wiley-Vch, (2007) - G.P. Lepage:
*Lattice QCD for Novices*, arXiv, (2005), http://arxiv.org/abs/hep-lat/0506036

### Module Exam

#### Description of exams and course work

There will be a written exam of 90 minutes duration. Therein the achievement of the competencies given in section learning outcome is tested exemplarily at least to the given cognition level using calculation problems and comprehension questions.

For example an assignment in the exam might be:

- Use the trapezoidal rule to calculate the integral of a function and show that the result is exact for linear functions.
- What is the order of magnitude of the error for non-linear functions (in terms of the step size and derivatives of the function to be integrated)?
- Taking into account the algorithmic error and the roundoff error, what is the optimum number of integration steps?

Participation in the exercise classes is strongly recommended since the exercises prepare for the problems of the exam and rehearse the specific competencies.

#### Exam Repetition

The exam may be repeated at the end of the semester.