Syllabus: CSC 4700: Parallel C++ for Scientific Applications (Spring 2025)

Course Summary

This course will focus on the parallel implementation of computational mathematics problems using modern parallel C++. The aim of this course is to learn how to quickly write useful and efficient C++ programs. The students will learn how to use high-level data structures, iterators, strings, and streams (including interactive and file I/O) of the C++ ISO Standard library. In addition, we will look into using highly-optimized linear algebra libraries since the course teaches to solve problems, instead of explaining low-level C++ and scientific computing algorithms.

My aim is for you to gain sufficient knowledge and experience to develop useful parallel programming applications using the best up-to-date techniques. Don’t expect to spend less time than maybe 15 hours a week for 14 weeks if you work by yourself.

The new C++23 international standard has been accepted this year. This is good news as it allows me to base all the course material on this new and revised language specification. Don’t be afraid, though. This will make your job easier. The revised C++ language is much easier to teach and to learn as many of the darker corners have been straightened out, and the overall appearance of the language is more homogeneous.

The approach taken in this course is “depth first” in the sense that it quickly moves through a series of basic techniques, concepts, and language supports before broadening out for a more complete understanding. Roughly the first half of the course concentrates on examples of using the standard library abstractions. In the second half of the course we will talk about how you can define and use your own abstractions in order to solve scientific computation problems by applying existing parallelization facilities from the standard C++ library.

The first part, provides a brief overview of the containers, strings, streams, input/output, and the numeric library of the C++ standard library. For linear algebra, we will look into Blaze which is an open-source, high-performance C++ math library for dense and sparse arithmetic. We will implement the following:

  • Adjacency matrices to perform graph analysis
  • Conjugate gradient solver and
  • A simple finite element solver

The second part will solve computational mathematics problems based-on the the previous introduced features of the C++ standard library. Here, we will implement the following:

  • A simple Monte Carlo method
  • N-Body simulations
  • Numerical integration
  • Finite differences
  • A simple solver for the heat equation using a stencil based code

The third part will focus on the parallel features provided by the C++ standard library. Here, the implemented computational problems in the second part of the course will be parallelized using the C++ standard library for parallelism and concurrency.

Since programming skills can only be improved by doing, there will be programming exercises and a small project. After this course students have a basic overview of the C++ standard library to solve efficiently computational mathematics problems without using low-level C/C++.

Prerequisites

  • None, but some basic knowledge about C++ is beneficial (CSC3380 using C++ would be a good starting point).
  • There are no other required prerequisites, except for willingness to learn and some interest in programming.

Office Hours

While I don’t have “office hours” in the conventional sense, I will stay around after lectures to answer questions. If this doesn’t work out, send me an email hkaiser@cct.lsu.edu and I will meet with you at another, more convenient time.

TA Email Hours
Shreyas Atre satre1@lsu.edu TBA

Lectures

Tuesdays and Thursdays, Time: 10:30am-11:50am, Place: 1212 PFT

Important Dates

  • Mardi Gras: March 3-5
  • Midterm exam: due March 17 (take home)
  • Spring break: March 31 - April 4

Project counts as final examination.

Both exams are comprehensive.

Reading

We will use material from the following books:

I suggest you acquire a copy of those for yourself. These books are not conventional textbooks and do not provide a gentle introduction to C++. If you feel you need some introductory textbook for C++, please consider:

Complementing this and the lectures, I recommend reading some of the following books, each of which is outstanding in its own right:

  • C++ Primer, 6th Edition by Stanley Lippman, Josée Lajoie, Barbara E. Moo. This books gives a comprehensive introduction into modern C++, it’s definitely one of the best text books for this.
  • Effective C++, More Effective C++, and Effective STL by Scott Meyers. These books are incredibly useful and will change the way you think and program in C++. The books in the Effective C++ series are collections of useful pieces of advice, so you can quickly navigate to relevant sections. While Meyers’ books are targeted at audiences with a solid understanding of core C++ language features, they should still be quite useful in the second half of the course.
  • The Design and Evolution of C++ by Bjarne Stroustrup. This most excellent book by the creator of C++ provides insight into the design decisions and overarching philosophy of C++. If you’re interested in how the language came to be, this is the definitive resource.

In Addition to the above books, I strongly recommend picking up a C++ language and library reference book for use in this class. Stroustrup’s The C++ Programming Language is an excellent choice.

Other resources:

Please don’t hesitate to ask questions related to the course by sending me email: hkaiser@cct.lsu.edu.

Projects, Homework and Quizzes

There will be up to five usually bi-weekly homework assignments. Those will be due at midnight (11:59pm Central Time) on the due date. A penalty will be applied if homework is late. For your final grade I will take into account all homework assignment results.

There will be one programming assignment (project) that will be due at midnight (11:59pm Central Time) of the due date. A penalty will be applied if the project is submitted late.

Occasionally we may have short quizzes (2-3 questions in 5 minutes) at the beginning of a lecture. These are mostly about things discussed in one of the previous lectures and shouldn’t require any special preparation – if you follow the lectures, that is.

You will be responsible for regularly following any course related information, such as homework assignments and due date announcements on the course website.

Important note: in this course, we will manage assignments and the project in repositories hosted on Github. The moment you accept an assignment on Github Classroom, you will get access to your own repository that is a clone of the original repository containing the starter code. Your clone of this repository is private by default. This means that nobody except yourself and the course staff is able to see it.

You are responsible to keep the visibility of the repository and its content private. If you change your repository’s visibility to public or make the content of your repository available to others in any way, then you make yourself vulnerable to allegations of plagiarism - with all related consequences.

Please be also aware that by accepting an homework assignment you agree on sharing your name and your LSU email address in the context of this course with Github. Please be aware that the work you turn in for this course, along with the respective student identifiers will be submitted to Github for review, for providing feedback, for performance analysis, and for grading purposes.

Grading

  • Homework 50%
  • Project 40% (counts in part as the final examination)
  • Midterm exam 10%

Overall, in the end of the semester 90% of all points or more will give you an ‘A’, 80% or more a ‘B’, 70% or more a ‘C’, and 60% or more results in a ‘D’. The letter grades ‘A’, ‘B’, and ‘C’ have the suffix plus (+) or minus (-) included to distinguish higher and lower performances within each of these letter grades. Below 70% you’ll fail the course, but I’m sure that will not happen to anyone.

Topics

The following list indicates roughly how much time we will spend on each topic:

No. of Weeks Topic
1-5 C++ review, strings, vectors, lists, stacks, queues
6-11 Library algorithms and data structures
12-15 Scientific computing using parallel C++

There is a full lecture calendar available on the course webpage outlining the topics in more detail. There will also be some flexibility in shortening some of these topics and adding other advanced topics as we go.

Course Policies

Grading Policies

It is course policy that whoever graded something will be responsible for handling grading disputes. I will grade the midterm exam and the final exam. The grader will grade the homework and the project. Grades become final one week after homework or exam is handed back. This should leave ample time to resolve grading disputes. All submissions are subject to our Late Policy.

Homework Standards

All homework and the project have to be submitted using the electronic submission mechanism as outlined in an appendix to the first homework assignment. All work submitted must carry the student’s name and must be reasonably neat and well organized. Any work that cannot be read easily will score zero points. A reasonable standard of English expression and grammar is also required. The same requirements apply to exams. Additional requirements may apply for any of the separate assignments and will be outlined in the corresponding descriptions.

Programming Standards

The algorithm used must be essentially correct. Obviously, the program should (compile and) run. Because of the complexity of the programs, no credit can be given for a program that doesn’t run. If a program core dumps, only partial credit will be given.

Honesty

I will treat you as professionals, and you should plan on conducting yourself as such. This course presents many important concepts you will need throughout your career as a computing professional, so it is important that each student do all the assignments and projects and learn the material.

You are free to discuss homework assignments and the project with others. In fact, I encourage you to do so. However, the solutions you submit are to be developed by yourself. Cheating is a very serious offense and will not be tolerated. Supplying others with homework solutions or material is also forbidden.

The policy is that the supplier and the receiver of information will both be dealt with in accordance with and as outlined by the LSU Code of Student Conduct.

Laptops

I’m not generally opposed to you using laptops during the lectures. Many students either take notes or try to find additional references helping them to follow the material. But unfortunately the experience shows that laptops may pose a major distraction not only for those using them but as well for the students sitting around. Please understand that I may have to restrict the use of laptops in class at some point.