Introductory course in Computational Physics, including linear algebra, eigenvalue problems, differential equations, Monte Carlo methods and more.
The material here aims at giving you an introduction to several of the most used algorithms in Computational Science. These algorithms cover topics such as advanced numerical integration using Gaussian quadrature, Monte Carlo methods with applications to random processes, Markov chains, integration of multidimensional integrals and applications to problems in statistical physics and quantum mechanics. Other methods which are presented are eigenvalue problems, from the simple Jacobi method to iterative Krylov methods. Popular methods from linear algebra are also discussed. A good fraction of the course is also devoted to solving ordinary differential equations with or without boundary conditions and finally methods for solving partial differential equations. You will also find material on popular Machine Learning algorithms, starting with various linear regression methods and ending with neural networks. The focus for the Machine Learning algorithms is on supervised learning.
The course is project based and through various projects, normally four to five, you will be exposed to fundamental research problems from various fields (Physics, Geophysics, Chemistry, Mathematics, Statistics etc), where, if possible, we aim at reproducing state of the art scientific results. You will learn to develop and structure codes when solving the projects, develop a critical understanding of the strengths and limits of the various numerical methods, become familiar with supercomputing facilities and parallel computing and learn to write scientific projects.
This course will be delivered in a hybrid mode, with online lectures and on site or online laboratory sessions.
Grading scale: Grades are awarded on a scale from A to F, where A is the best grade and F is a fail. There are three projects which are graded and each project counts 1/3 of the final grade. The total score is thus the average from all three projects.
The final number of points is based on the average of all projects (including eventual additional points) and the grade follows the following table:
Course participants are expected to have their own laptops/PCs. We use Git as version control software and the usage of providers like GitHub, GitLab or similar are strongly recommended.
We will make extensive use of C++ and/or Python as programming language and its myriad of available libraries. You can also use compiled languages like Rust, Julia, Fortran etc if you prefer. Beware that in case you use Rust or Julia we may not be able to help you properly at the lab.
The focus during the lectures will be on C++. Please read the intro to C++ programming at http://compphysics.github.io/ComputationalPhysics/doc/pub/learningcpp/html/learningcpp-bs.html
This link contains info about installing compilers as well.
If you have Python installed and you feel pretty familiar with installing different packages, we recommend that you install the following Python packages via pip as
For OSX users we recommend, after having installed Xcode, to install brew. Brew allows for a seamless installation of additional software via for example
For Linux users, with its variety of distributions like for example the widely popular Ubuntu distribution, you can use pip as well and simply install Python as
If you don't want to perform these operations separately and venture into the hassle of exploring how to set up dependencies and paths, we recommend two widely used distrubutions which set up all relevant dependencies for Python, namely
which is an open source distribution of the Python and R programming languages for large-scale data processing, predictive analytics, and scientific computing, that aims to simplify package management and deployment. Package versions are managed by the package management system conda.
is a Python distribution for scientific and analytic computing distribution and analysis environment, available for free and under a commercial license.
Furthermore, Google's Colab:https://colab.research.google.com/notebooks/welcome.ipynb is a free Jupyter notebook environment that requires no setup and runs entirely in the cloud. Try it out!
Here we list several useful Python libraries we strongly recommend (if you use anaconda many of these are already there)
Recommended textbooks: - Morten Hjorth-Jensen, Introduction to Computational Physics, IoP, in press. The version from 2015 at https://github.com/CompPhysics/ComputationalPhysics/blob/master/doc/Lectures/lectures2015.pdf will be updated shortly. - Philipp O.J. Scherer, Computational Physics, Simulation of Classical and Quantum Systems, https://www.springer.com/gp/book/9783319610870 (can be downloaded for free if you are connected with a UiO IP-number).
As of now this is not required, but the situation may change. If face covering will be required during the semester, we will fill in more details.
We will be practicing physical distancing in the classroom dedicated to the lab sessions. Thus, everybody should maintain at least one meter distance between themselves and others (excluding those with whom they live). This applies to all aspects of the classroom setting, including seating arrangements, informal conversations, and dialogue between teachers and students.
All participants attending the laboratory sessions must maintain proper hygiene and health practices, including: * frequently wash with soap and water or, if soap is unavailable, using hand sanitizer with at least 60% alcohol; * Routinely cleaning and sanitizing living spaces and/or workspace; * Using the bend of the elbow or shoulder to shield a cough or sneeze; * Refraining from shaking hands;
Course participants will (a) look for instructional signs posted by UiO or public health authorities, (b) observe instructions from UiO or public health authorities that are emailed to my “uio.no” account, and (c) follow those instructions. The relevant links are https://www.uio.no/om/hms/korona/index.html and https://www.uio.no/om/hms/korona/retningslinjer/veileder-smittevern.html
Students will self-monitor for flu-like symptoms (for example, cough, shortness of breath, difficulty breathing, fever, sore throat or loss of taste or smell). If a student experiences any flu-like symptoms, they will stay home and contact a health care provider to determine what steps should be taken.
If a student is exposed to someone who is ill or has tested positive for the COVID-19 virus, they will stay home, contact a health care provider and follow all public health recommendations. You may also contact the study administration of the department where you are registered as student.
Those who come to UiO facilities must commit to the personal responsibility necessary for us to remain as safe as possible, including following the specific guidelines outlined in this syllabus and provided by UiO more broadly (see links below here).
See https://www.uio.no/om/hms/korona/index.html and https://www.uio.no/om/hms/korona/retningslinjer/veileder-smittevern.html. For English version, click on the relevant link.