10 - SP - Introduction To Python - Demonstration of Its Capabilities in Scientific Research For Civil Engineering
10 - SP - Introduction To Python - Demonstration of Its Capabilities in Scientific Research For Civil Engineering
2
Python
• a high-level, interpreted programming language
• Designed by Guido van Rossum and first released in 1991
• Multi-Platform Compatible (Win, Linux, macOS)
3
Python is …
4
Growth of Python
source: source:
https://machinelearningmastery.com/python- https://medium.com/@abdullahassami/why-you-
growing-platform-applied-machine-learning/ should-start-learning-python-in-2023-f79ecb0525bc
5
Potential
Usecases for
Python
• Data Analysis and Data
Visualization
• Machine Learning and Artificial
Intelligence
• Scientific Computing
• Automation and Scripting
• Web Development
• Many More…
6
Advantages and Drawbacks
Pros Cons
• Free and Open-Source • speed limitations
• Vast and versatile Libraries • not memory efficient
• Supportive Community
• High-Level-Programming Language
• High Productivity
• High readability
• Well described Error Messages
7
Overview
• What is Python?
• Getting started | Installation
• Basic Code Syntax
• Examples
8
Getting started | Installation
• Python 2, Python 3.11, … • VSCode
• Pycharm
• Jupyter
• Spyder
• Anaconda
15
Python Basics
Output
16
Python Basics
Dynamically Typed Variables and Types
17
Python Basics
Control Structures (Conditional Statement and Loop)
18
Python Basics
Functions
19
Python Basics
Modules | Packages
20
Overview
• What is Python?
• Getting started | Installation
• Basic Code Syntax
• Packages and Examples
21
Getting started | PIP
Package Installer for Python
22
„numerical operations“
• Numpy Arrays
• Curve fitting (Polynomial fit, Interpolation, …)
• Matrix Operations
• Fourier Transformation
• Sparse Arrays
• Input/Output (Matlab, HDF5, NetCFD , Images, WAV, TXT, …)
• Optimization (Nelder-Mead, BFGS, Differential Evolution, …)
• Signal Processing (Filtering, Peak Identification, …)
• Integration, Deviation, ….
30
Find your learning resources!
31