Computational Physics 2024, Course 509 - Physics Applications of Computers

Graduate CompPhys

Undergrad CompPhys

Advanced Grad CompPhys

Many body physics

Quantum Mechanics

Advanced Solid State

E&M



  
Left: Simulation of a bacteria growth by DLA method, Right: Molecular dynamics simulation of a small system of atoms.

This course introduces algorithmic concepts and familiarizes students with basic computational tools essential for graduate students in computational physics. These tools are also highly beneficial to most graduate students in STEM and related fields, as well as those planning to pursue careers in the IT industry.

In this course, students will work toward mastering computational skills and basic algorithms relevant to classical and quantum physics. However, the course is not limited to these fields. For example, large-scale minimization problems, high-dimensional integration problems, and solving partial differential equations make up the bulk of the course. These same algorithms are also widely applicable across all STEM fields and are used by quantitative analysts in major banks. While the examples are primarily drawn from quantum physics, their applicability extends far beyond this specific subfield.

The primary programming language for this course will be Python, along with its scientific libraries, SciPy and NumPy. To optimize certain parts of the code, we will also use C++ (with pybind11) and Fortran90 (f2py) for brief examples, which will be accessed through the Python interface.

This course has no prerequisites other than familiarity with a programming language. It is designed for students who wish to broaden their knowledge of applications and develop new techniques. To complete the homework and participate in hands-on training, students are encouraged to use their own laptops and bring them to class (for in-person sessions).


Class Time: ARC 107 10:20pm-11:40pm Monday and Thursday

Instructor: Kristjan Haule
Office: Serin E267
email: haule@physics.rutgers.edu
Phone: 445-3881
Office hours: after lecture

 

Classes that need to be rescheduled: Sept 9, Spet 12, Oct 28, Oct 31. Could be reschedules at the following dates: Dec 12, Dec 16, Dec 19.
Youtube videos from 2021: Lecture 1, Lecture 2, Lecture 3, Lecture 4, Lecture 5, Lecture 6, Lecture 7, Lecture 8, Lecture 9, Lecture 10, Lecture 11, Lecture 12, Lecture 13, Lecture 14, Lecture 15, Lecture 16, Lecture 17, Lecture 18, Lecture 19, Lecture 20, Lecture 21, Lecture 22, Lecture 23, Lecture 24, Lecture 25, Lecture 26

Course Outline and Tentative List of Topics

A) Introduction to computation

  1. Installation and Mandelbrot set, jupyter nb: Introduction_to_Comp_Phys_509.ipynb
  2. Interactive Mandelbrot & self-similarity, jupyter nb: Interactive MandelbrotSet.ipynb, python script: manp_dynamic.py
  3. Logistic map and fractals, Lyapunov exponent and chaos, jupyter nb: Logistic map.ipynb
  4. parallelization with openMP, pi_examp.cc
  5. Numerical error accumulation and Miller's algorithm, jupyter nb: Numerical_Error.ipynb


B) Learning Python programming (Numpy, SciPy, Pylab)

  1. Jupyter introduction, jupyter nb: 00_Introduction.ipynb
  2. Python syntax, jupyter nb: 01_Basic_Python.ipynb
  3. Numpy, jupyter nb: 02_Numpy.ipynb
  4. Scipy, jupyter nb: 03_Scipy.ipynb
  5. Hydrogen atom & scipy, jupyter nb: 04_Scipy_Hydrogen_atom.ipynb
  6. Atom with LDA, jupyter nb: 05_Atom_in_LDA.ipynb
This lectures are adopted from https://github.com/jrjohansson/scientific-python-lectures

Homeworks:
    Homework 3,     Numerov algorithm
    Homework 4,      Script for XC potential: excor.py
    Total energies from NIST (Energies are given in Hartree's)

More literature on Learning Python:
  • Software carpentry
  • How to Think Like a Computer Scientist: Learning with Python
  • Python for beginners
  • Python documentation
  • Python regular expressions

  • C) Monte Carlo and Simulated Annealing
    1. Random numbers, multidimensional Vegas integration (Vegas_code, jupyter nb: Vegas_2021.ipynb)
    2. Classical Monte Carlo & Simulated Annealing
    3. High-Dimensional integration by Metropolis, jupyter nb: highd_int.ipynb, mweight.py
      Homework for high-D integration by Metropolis

    Alternative implementation of Ising: online Ising model simulation

    Other Source Codes:
  • C version of High-D integration
  • Diffusion limited aggregation
  • Other MC codes

  • D) Machine Learning
    1. Linear regression, pdf ( jupyter notebook, NucleousEnergy.dat)
    2. Logistic regression, pdf ( jupyter notebook)
    3. Deep Learning, pdf (jupyter notebook,NNfig.pdf,or_xor.pdf,NN_digits.pdf)

    E) Parallel Programing
    1. Parallel programming with MPI ( source code)
    F) Basic numerical methods:
    1. Numeric integration (source code)
    2. Interpolation, Splines and Fourier transformation (source code)
    3. Differential equations (source code)
    Literature: Numerical Recipes online

    G) More advanced topics in Computational Condensed Matter physics:
    1. Hartree-Fock method
    2. Density functional theory
    3. Quantum Monte Carlo methods
    4. Continuous Time Quantum Monte Carlo method
    5. Molecular dynamics simulation
    Literature:
    1. Computational Physics by J.M. Thijssen
    2. An introduction to Computer Simulation Methods by H. Gould, J Tobocnik and W. Christian
    3. Electronic Structure, Basic Theory and Practical Methods by Richard M. Martin(Very good book for the Density functional part of the course)
    4. An Introduction to Computational Physics by Tao Pang
    5. Computational Physics by Rubin H. Landau and Manuel J. Paez(More elementary but good book)

    Students with Disabilities