Athanasios Chatzistavrakidis was awarded with NAWA's Ulam Fellowship and will join us for six month

Computational Methods I

USOS

A visualization of the  Mandelbrot set This is the mandatory Computational Methods I course of the Master in Theoretical Physics at the University of Wrocław. It is tailored towards master and PhD students who are familiar with

  • computers and their operating systems (Linux is preferred, but Windows or MacOS will work, too)
  • at least one programming language, ideally Python which we will use in the course
  • classical and quantum mechanics.

There are many good books on the subject, four that I like are

  • Landau , Páez, Bordeianu: Computational Physics: Problem Solving with Python
  • Scherer: Computational Physics - Simulation of Classical and Quantum Systems
  • Matthes: Python Crash Course - A Hands-On, Project-Based Introduction to Programming
  • Johansson: Numerical Python

There will be 2 hours of lectures and 2 hours of labs each week. Exercises will be posted here a week before the tutorial they are discussed in. Please keep in mind that active participation in the labs and especially submitting the solution to the posed problems is important to pass the course. M.Sc. Biplab Mahato will be the assistant for this course. Please fell free to contact him () or me if you have any questions. For information about credits points, please refer to the syllabus or contact me directly.

Location: There have been some changes of lecture room. We are now in the computer lab 120 for both, the lectures and the labs.

Recordings/hybrid participation: The lectures will be streamed on YouTube with the link for each of them given below. This should help if you are not able to physically attend.

Exam: As discussed during the first lecture, we will have individual projects for the exam. If you have any project idea, we are very happy to hear about it and then decide together how to best implement it. Here are a couple of ideas which might help you

  1. Molecular Dynamics Simulations

    Simulate the behavior of a gas or liquid using molecular dynamics. For example implement the Lennard-Jones potential and study properties like diffusion, temperature, or phase transitions.

  2. Quantum Mechanics Simulations

    Solve the Schrödinger equation for a coherent state in the stadium billiard and compare its time evolution with the classical trajectory. Plot some of the eigenfunctions and discuss their properties.

  3. Monte Carlo Methods

    Implement a Monte Carlo simulation of the 2-dimensional Ising model or percolation. Explore random sampling techniques, convergence properties and/or phase transitions.

  4. Astrophysical Simulations

    which is either a) N-body simulations or b) solve the TOV equation

  5. Electromagnetic Wave Propagation

    Model the propagation of electromagnetic waves in various media. Implement the Finite-Difference Time-Domain (FDTD) method to study wave behavior, reflection, and refraction.

  6. Chaos and Dynamical Systems

    Explore chaotic systems, such as the logistic map or Lorenz attractor. Focus: Analyze stability, bifurcations, and strange attractors (other than the Lorenz attractor) using numerical methods.

  7. Quantum Computing Simulations

    Simulate simple quantum algorithms (e.g. Grover's, and Shor's algorithm or quantum teleportation). Implement quantum gates and circuits using Python with libraries such as Qiskit.

Once you have chosen a project and it is approved by us, you will prepare your Python code, a small documentation and some of the most important results and submit them to us by January the 31st 2025. Please send everything to Biplab and me via email. After this, you will have a 10-minute presentation of your results during the exam session (dates and times will be coordinated) followed by 5 minutes of discussion.

For the last three tutorials, there will be no assignments. Instead you have the chance to discuss challenges you encounter in your project.

Development environment: In this course we will use the programming language Python with a notebook interface, called Jupyter notebooks. To get all this running, and avoid possible problems with incompatible versions of Python packages, we will use a standardized development environment. To set it up, please first install Visual Studio Code. On Linux, you will most likely have it already in your package manager. Alternatively, you can also download it here. Next, you need to clone the git repository for this course. To this end, open VS Code and click on the two documents (Explorer, Ctrl+Shift+E) to find something which looks like this

Clone a repo in VS code

Now, click on "Clone Repository" and enter the URL of our git repository

https://www.fhassler.de/git/public/ComputationalMethodsI

like this

Enter the repo's URL

Finally you have to install all packages for the virtual environment, we use to run our Python code and notebooks. In the main menu, click on Terminal and then Run Build Task... (Ctrl+Shift+B). After this you should see some activity in the terminal on the bottom of the screen. If there are no errors, you have successfully installed the virtual environment. Now you are ready to add your own notebooks or run some of the already provided.

Additional material for the individual lectures, including the exercises which we discuss in the labs, is given below:

  1. A quick introduction to Python
    Lecture04.10.2024 06:15, notes, notebook, show recording
    Tutorial04.10.2024 08:15, exercise
  2. Different representations of numbers and their numerical errors
    Lecture11.10.2024 06:30, notes, notebook, show recording
    Tutorial11.10.2024 08:15, exercise
  3. Numerical differentiation and integration
    Lecture18.10.2024 06:30, notes, notebook, show recording
    Tutorial18.10.2024 09:15, exercise

    I have updated the virtual environment to include the libraries scipy and sympy. You can just pull the most recent version from the git and run the build task again (like described above) to be able to use these libraries.

  4. Ordinary differential equations
    Lecture25.10.2024 06:30, notes, notebook, show recording
    Tutorial25.10.2024 09:15, exercise
  5. Classical dynamics with regular and chaotic behavior
    Lecture08.11.2024 07:30, notes, show recording
    Tutorial08.11.2024 10:15, exercise

    You might be interested to see a real, physical double pendulum after this lecture. Moreover you can play with the corresponding Poincare-map.

  6. Methods to solve non-linear equations
    Lecture20.11.2024 07:30, notes, notebook, show recording
    Tutorial20.11.2024 10:15, exercise
  7. Iteration, bifurcation, self-similarity and chaos
    Lecture22.11.2024 07:30, notes, notebook, show recording
    Tutorial22.11.2024 10:15, exercise
  8. Linear algebra, in particular finding eigenvalues and eigenvectors
    Lecture29.11.2024 07:30, notes, show recording
    Tutorial29.11.2024 10:15, exercise
  9. Quantum dynamics, tunneling in a double-well potential
    Lecture06.12.2024 07:30, show recording
  10. Generating random numbers
    Lecture13.12.2024 09:15, show recording
  11. Brownian motion and the random walk
    Lecture20.12.2024 07:30, show recording
  12. Monte-Carlo simulations
    Lecture10.01.2025 07:00
  13. The two dimensional Ising model
    Lecture17.01.2025 07:00
  14. Partial differential equations
    Lecture24.01.2025 07:30
  15. Neural networks
    Lecture31.01.2025 07:30
Based on course 13, last update on November 28th 2024, 14:28:57 | Build 628 on December 2nd 2024, 13:35:12 | Times and dates shown in UTC+00:00 | Contact