數值軟體開發(英文授課)
Numerical Software Development
| 節 | 週一 |
|---|---|
Z 07:00–07:50 | 數值軟體開發(英文授課) EC114(光復) 3 節連堂 |
1 08:00–08:50 | |
2 09:00–09:50 |
* 根據陽明交大上課時間表所列
This course discusses the art to build numerical software, i.e., computer programs applying numerical methods for solving mathematical or physical problems. We will be using the combination of Python and C++ and related tools (e.g., bash, git, make, etc.) to learn the modern development processes. By completing this course, students will acquire the fundamental skills for developing modern numerical software. Check course notes for details: https://yungyuc.github.io/nsd .
This is a graduate or senior level course open to students who have taken computer architecture, engineering mathematics or equivalents. Working knowledge of Linux and Unix-like is required. Prior knowledge to numerical methods is recommended. The instructor uses English in the lectures and discussions.
無備註
The instructor will use English. It is OK for students to use Mandarin in the class, but English is preferred. Computer program for homework and project should be developed against the latest Ubuntu LTS system. AWS Machine Image (AMI) and AWS educate will be used.
* You are expected to learn programming languages yourself. Python is never a problem, but you could find it challenging to self-teach C++. Students are encouraged to form study groups for practicing C++, and discuss with the instructor and/or the teaching assistant. * Grading: homework 30%, mid-term exam: 30%, term project: 40%. * There are 14 lectures for the subjects of numerical software developing using Python and C++. * There will be 6 homework assignments for you to exercise. Programming in Python and/or C++ is required. * Mid-term examination will be conducted to assess students' understandings to the analytical materials. * Term project will be used to assess students' overall coding skills. Presentation is required. Failure to present results in 0 point for this part.
Introduction
What is numerical software.
Fundamental engineering practices
A large chunk of efforts is spent in the infrastructure for coding. The key to the engineering system is automation.
Python and numpy
Python is a popular choice for the scripting engine that makes the numerical software work as a platform.
C++ and computer architecture
The low-level code of numerical software must be high-performance. The industries chose C++ because it can take advantage of everything that a hardware architecture offers while using any level of abstraction.
Matrix operations
Matrices are everywhere in numerical analysis. Arrays are the fundamental data structure and used for matrix-vector, matrix-matrix, and other linear algebraic operations.
Cache optimization
How cache works, its importance to performance, and optimization with cache.
SIMD (vector processing)
Parallelism and x86 assembly for SIMD.
Memory management
Numerical software tends to use as much memory as a workstation has. The memory has two major uses: (i) to hold the required huge amount of data, and (ii) to gain speed.
Smart pointers
Ownership and memory management using C++ smart pointers.
Modern C++
Copy elision and move semantics. Variadic template and perfect forwarding. Closure.
C++ and C for Python
Use C++ and C to control the CPython interpreter.
Array-oriented design: Array code in C++
Dissect the array-based code and element-based code and when to use them.
Array-oriented design: system
Software architecture that take advantage of array-based code.
Advanced Python
Advanced topics in Python programming.
| 週次 | 主題 |
|---|---|
| 第 1 週 | Lecture 1: Introduction & Fundamental engineering practices (homework #1) 2/22 |
| 第 2 週 | Skip meeting on holiday (peace memorial) 3/1 |
| 第 3 週 | Lecture 2: Python and numpy (term project proposal start) 3/8 |
| 第 4 週 | Lecture 3: C++ and computer architecture (homework #2) 3/15 |
| 第 5 週 | Lecture 4: Matrix operations 3/22 |
| 第 6 週 | Lecture 5: Cache optimization (homework #3) 3/29 |
| 第 7 週 | Skip meeting on holiday (spring holidays) (term project proposal due) 4/5 |
| 第 8 週 | Lecture 6: SIMD 4/12 |
| 第 9 週 | Mid-term examination 4/19 |
| 第 10 週 | Lecture 7: Memory management (homework #4) 4/26 |
| 第 11 週 | Lecture 8: Smart pointers 5/3 |
| 第 12 週 | Lecture 9: Modern C++ (homework #5) 5/10 |
| 第 13 週 | Lecture 10: C++ and C for Python 5/17 |
| 第 14 週 | Lecture 11: Array-oriented design (homework #6) 5/24 |
| 第 15 週 | Lecture 12: Advanced Python 5/31 |
| 第 16 週 | Term project presentation 6/7 |
| 第 17 週 | No meeting (optional lecture is not planned) 6/14 |
| 第 18 週 | No meeting (optional lecture is not planned) 6/21 |
Textbook: None References: * Computer Systems: A Programmer's Perspective: https://csapp.cs.cmu.edu/ * Python documentation: https://docs.python.org/3/ * Cppreference: https://en.cppreference.com/ * Effective Modern C++, Scott Meyer, O'Reilly, 2014 * Source code: cpython, numpy, xtensor, and pybind11
- 地點
- By appointment
- 時間
- N/A
- 聯絡方式
- Send email to yyc at solvcon.net, with "[nsd]" prefix in the subject line.
