An Introduction to Python

These are notes I made as I have explored Python. My documentation uses Jupyter Notebook—a web application that binds live code, equations, visualizations, and text into a single web-based framework. The notebook contains panels in which you write code, and others in which you can write notes. The latter uses a language called markdown, and permits embedding html and LaTex. On this page you will find links to notebooks describing Python topics. These links display html documents containing Python code, the results of running each script, and notes about the program. The html documents do not contain “live code”. They are a web-based record of a snippet of code run in Python. You can, however, copy the code part of the display and paste it into a new Jupyter notebook and run the .ipynb file, or you can paste into any Python IDE app to run. You can download Jupyter notebook from www.anaconda.com. Installing Anaconda will give you access to not only Jupyter Notebook, but also a host of other advanced data science apps.

0. First Steps

0.1 What is Object Oriented Programming?
  This is a very good description of Object Oriented Programming without details of any language.
0.2 Getting Started
  Some practical matters for the beginning user by www.pythonlikeyoumeanit.com.

1. Python Basics

2. Python Packages

2.1 Numpy
 NumPy is a Python library used for working with arrays.It also has functions for working in domain of linear algebra, fourier transform, and matrices.It is an open source project and you can use it freely. NumPy stands for Numerical Python.
2.2 Matplotlib
 Matplotlib is a comprehensive library for creating static, animated, and interactive visualizations in Python. Matplotlib makes easy things easy and hard things possible.
2.3 tkinter
 Python has a lot of GUI frameworks, but Tkinter is the only framework that’s built into the Python standard library. Tkinter has several strengths. It’s cross-platform, so the same code works on Windows, macOS, and Linux. Visual elements are rendered using native operating system elements, so applications built with Tkinter look like they belong on the platform where they’re run.

2.4 Scipy
 SciPy is a collection of mathematical algorithms and convenience functions built on the NumPy extension of Python. It adds significant power to the interactive Python session by providing the user with high-level commands and classes for manipulating and visualizing data.
2.5 Pandas
 pandas is a fast, powerful, flexible and easy to use open source data analysis and manipulation tool, built on top of the Python programming language.

3. Creating Your Own Python Objectss

3.1 Objects, Classes, Subclasses, and Instantiation
3.2 Modeling Particle Dynamics Using OOP
3.3 Modeling a Wine Library using OOP
 The objects modeled in this script are bottles of wine. User interaction is enabled with tkinter. The user can select all bottles in the library with the same attribute (winery,varietal, or vintage), or a display can be generated to visually present a storage rack of wine with bottle attributes displayed in appropriate slots.

4. Symbolic Computing and Sympy

SymPy is a Python library for symbolic mathematics. It aims to become a full-featured computer algebra system (CAS) while keeping the code as simple as possible in order to be comprehensible and easily extensible. SymPy is written entirely in Python.
4.1 Basics
 NumPy is a Python library used for working with arrays.It also has functions for working in domain of linear algebra, fourier transform, and matrices.It is an open source project and you can use it freely. NumPy stands for Numerical Python.
4.2 Differentiation and Integration
 Matplotlib is a comprehensive library for creating static, animated, and interactive visualizations in Python. Matplotlib makes easy things easy and hard things possible.
4.3 Vectors and SymPy Plots
  Matplotlib is a comprehensive library for creating static, animated, and interactive visualizations in Python. Matplotlib makes easy things easy and hard things possible.
4.4 Multivariable Calculus
  

5. SimPy: Discrete Event Simulation

PROJECTS

This section includes a variety of projects building on the skills developed in the preceeding sections. A project does not imply large complicated Python code, but an application to a situation which involves more than a one sentence description of the problem.

P1 Tennis Ball Dynamics
  This project arose from a homework assignment in a high school senior level physics course. I originally solved the problem using paper and pencil (which solution is included here) but later implemented a soulution using Python and the sympy package. Sympy is not needed; you could easily use Scipy in constructing the Python code.
P2 Developing Tic-Tac-Toe game using tkinter
P3 Modeling a Wine Library using OOP
 The objects modeled in this script are bottles of wine. User interaction is enabled with tkinter. The user can select all bottles in the library with the same attribute (winery,varietal, or vintage), or a display can be generated to visually present a storage rack of wine with bottle attributes displayed in appropriate slots.
P4 Development of a Wordle Game
P5 Modeling Highway Congestion using OOP Models
P6 Modeling the Dynamics of the COVID Pandemic
P7 Some Interesting Characterizations of the Orbit of the James Webb Space Telescope
Under Construction

If you have any questions, you can email me at drfalken@comcast.net

 

Last updated 10/2/2023
© Donald R. Falkenburg

Valid XHTML 1.0 Transitional