You are on page 1of 16

0.

A Wrap Up March 21, 2011

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 1 of 16

Outline

Important concepts of C/C++ &

missing topics.
Further literature & lectures.

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 2 of 16

Missing C++

Static variables (class variables; see

slides of session 10)


Standard library (STL)

Containers Iterators Math library

Exceptions & error handling Outlook to C++Ox

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 3 of 16

Important Concepts (1/2)


von-Neumann architecture, and, in particular, the linearised memory. Denition of an algorithm. Interplay of compiler, linker, interpreted programs, and machine language. Idea of a variable and its instantiation. Overview of built-in data typesplease note the default-value paradigm in context

with default constructors.


Terms syntax and semantic. Comments. Assignment statements (equal sign) in combination with case distinction. An idea of the rounding error (normalisation process). Strict vs. non-strict boolean logic. Different variants of branches and loops.

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 4 of 16

Important Concepts (2/2)


Scopes. Notion of a function and the three call paradigms. Keyword const in different context. Recursion and its different types. Enums. Split-up of an application into header and implementation les. Pointers, arrays, and strings. Concept of 0-terminated strings. Structures (n-tupels). Dynamic memory management. Encapsulation. Methods instead of functions on structs. Constructor and destructor concept. Inheritance.
0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 5 of 16

The three pillars of science

Theory

Simulation Experiment

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 6 of 16

The didactic concept revisited

In theory there is no difference between theory and practice. In practice there is.

Yogi Berra

We didnt practiceno even in the tutorialsbut just started to train the very basics. So far, theres no arts involved.
0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 7 of 16

Further literature & topics


Martin Fowler: Refactoring Erich Gamma, Richard Helm, Ralph Johnson, John M. Vlissides. Design Patterns:

Elements of Reusable Software


Randall Hyde: Write Great Code I: Understanding the machine Randall Hyde: Write Great Code II: Thinking Low-level, Writing High-level Scott Meyers. Effective C++ Scott Meyers. More Effective C++

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 8 of 16

The Scientic Workow

Numerical Experiments Postprocessing Visualisation

Modelling

Numerical Treatment

Design of Software

Implementation Tests

In math, theres tons of lectures on pre-coding topics. In computer science and, in particular, in the application areas, theres tons of lectures on the post-coding and modelling topics.
0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 9 of 16

Coding & scientic computing continued


Parallel Numerics
Winter term. Prof. Dr. Thomas Huckle Study (mainly) linear algebra with

respect to parallelisation
Use MPI with C programming

language

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 10 of 16

Coding & scientic computing continued


Algorithmen des wissenschaftlichen Rechnens Algorithms of Scientic Computing
Summer and winter term. Prof. Dr. Hans-Joachim Bungartz et. al. FFT, SFCs, and hierarchical models (part I) Sparse grids, molecular dynamics, AMG (part II)

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 11 of 16

Coding & scientic computing continued


CDF Lab
Summer term. Philipp Neumann et. al. Program a CFD solver (almost from

skratch)
following the book from Griebel et. al. in four sessions.

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 12 of 16

Projects, Hiwis, etc.

In theory there is no difference between theory and practice. In practice there is.

Yogi Berra

Use the time you have at the university to train and play around ... (youll sit in a company later way too long anyway)
0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 13 of 16

FRAVE

Showcase room of computer science department. Several codes (most of them in C/C++). Nice starting point to get an impression about what is going on in Scientic

Computing.

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 14 of 16

Peano

Big C++ project kicked-off at the chair. Open source, and available at www5.in.tum.de/peano. Feel free to download it and study a

real-world PDE piece of software.

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 15 of 16

Good luck ...

... and see you all at the exam!

0. A Wrap Up Einfuhrung in die ProgrammierungIntroduction to C/C++, Tobias Weinzierl page 16 of 16

You might also like