
Streamline scientific workflows with Python in seven hours. Master Monte Carlo methods, differential equations, curve fitting, and Brownian motion using NumPy, SciPy, Matplotlib, and Pandas.
Learn to install and set up Python with Anaconda, including the Anaconda Navigator, Jupyter notebooks, Spyder, and Notepad Plus Plus with PowerShell to write and run code.
Learn to code in Spyder, an integrated editor to write and execute Python, view variables in the explorer, and plot data with numpy and matplotlib.
Learn to write and run Python code with Notepad++ as a lightweight editor; save scripts, navigate directories in PowerShell, and execute files to see plots and iterate with for loops.
Explore how to write and execute Python code in JupyterLab notebooks, using cells, markdown, and plots, and export notebooks to HTML or Python scripts for sharing, with notebooks locally executed.
Explore Monte Carlo methods in Python to estimate pi by sampling random points in a unit square and counting those within a unit circle, linking area ratios to pi.
Generate random points in a unit square with numpy and plot them to visualize distribution. Distinguish points inside the unit circle to illustrate a Monte Carlo approach for estimating pi.
Apply the Monte Carlo method by randomly distributing points in a square, counting those inside the circle with a boolean test, and estimate pi from area ratios.
Show Monte Carlo estimation of pi by varying sample sizes from 100 to 1,000,000, tracking estimates and percent error against NumPy's pi, stored in NumPy arrays for plotting.
Learn Monte Carlo integration to estimate multidimensional integrals using random samples and function evaluations. Implement the method in Python by scaling the average of sample values by the integration volume.
Use Monte Carlo integration to estimate a two-dimensional normalized gaussian by sampling points in minus five to five, evaluating f, and visualizing with a grid and pcolormesh.
Use Monte Carlo integration by sampling random points within the integration region, multiply the average function value by the region’s volume, and compare with SciPy's quad.
Develop a dimension-agnostic Monte Carlo integrator in Python by defining an integrate function, generating random points across multi-dimensional limits, and evaluating high-dimensional functions for fast, scalable integration.
Learn to solve the damped harmonic oscillator differential equation in Python by defining the state, initial conditions, and using an ode solver to simulate time evolution.
Explore visualizing a damped harmonic oscillator by plotting displacement and velocity, verify exponential energy decay using kinetic and potential energies, and compare numerical results to theoretical expectations.
Explore the harmonic oscillator's frequency response by computing the Fourier transform of displacement, validating the model against theory, and comparing differential equation solutions with resonance behavior.
Learn to solve coupled two-body gravitational differential equations in python, from 2d to 3d, plot trajectories in multiple planes, and encode velocity using color in insightful plots.
Set up two gravitating bodies, 1000 kg and 5000 kg, with positions and a slow velocity. Solve the initial value problem over 10 million seconds and plot their trajectories.
Generalize the orbital solver from two dimensions to higher dimensions by adapting the state vector to n dimensions, enabling three-dimensional satellite orbit calculations.
Visualize the three dimensional trajectory of two bodies under gravity by plotting the x y, x z, and y z planes with subplots, labeled axes, and starting points.
Learn to model Brownian motion in two dimensions using a zero-mean normal step distribution, accumulate steps to form trajectories, and plot a zero-start diffusion path with unit aspect ratio.
Compute the diffusion coefficient from Boltzmann constant, temperature, viscosity, and particle diameter, then simulate Brownian motion with a time step to generate the X and Y trajectories.
Compute mean square displacement for Brownian motion and compare experimental trajectories to the theoretical linear relation, highlighting dimension, diffusion coefficient, time, and effects of confinement or directed motion.
Simulate Brownian motion for multiple particles, compute their trajectories in two dimensions, and average the mean square displacement to compare with theoretical predictions.
Track particle trajectories in video data using a Brownian motion simulation, load frames with OpenCV, convert to grayscale, and stack frames into a 3D array for analysis.
Load a binary object file with pickle, extract pixel-to-meters scaling and trajectory data, convert to micrometers, and visualize the first frame using a mesh grid and color mesh.
Smooth frames with a caution filter (Gaussian kernel) controlled by sigma, locate the particle at the smoothed frame maximum, and track X and Y trajectories across frames.
Plot ground truth and tracked X and Y trajectories, align starts, and assess accuracy with RMSE, revealing nanometer-scale deviations and validating the particle tracking approach.
Performs parameter estimation by fitting a Laurentian distribution to experimental resonance data using curve fitting and optimization; extends to multimodal resonances and assesses fit quality.
Fit a Lawrence distribution to resonance data using curve_fit, estimate parameters I0, omega0, gamma, and convert between wave numbers, frequency, and angular frequency.
Load a multi spectrum from a text file with several resonances and fit them as a sum of Lorentz distributions, setting bounds for omega zero, gamma, and amplitude.
Apply nonlinear least squares to minimize the difference between the model and experimental data, using differential evolution for initialization and refined least-squares fitting under parameter bounds.
Compute the r-squared coefficient of determination to assess model fit using residuals and total variance; plot data with the model and extract resonance amplitudes, frequencies, and damping in wave numbers.
Explore fitting multiple resonances with careful initial parameters, then apply weights in the objective function via weighted least squares for frequency-dependent noise using provided spectra and trust regions.
Process tabulated data with pandas by loading a Kaggle peer reviews CSV and selecting key columns. Use describe to summarize the overall review and identify best and worst beers.
Compute frequency distributions of beer ratings with value_counts, filter the data by frequency, and plot a histogram showing most reviews cluster around 3.5 to 4.5 stars.
Learn to use pandas groupby to compute mean and standard deviation of beer ratings, map IDs to names, merge properties into a dataframe, and plot a histogram of mean ratings.
Sort mean reviews to identify top and bottom beers, evaluate controversy with standard deviation, apply 99th and 1st percentiles, and export to CSV with semicolon separators for mobile access.
Compute style-specific means and standard deviations to normalize beer ratings, then compare top and bottom beer styles by adjusted scores using grouped data and merged dataframes.
Demonstrates merging dataframes on beer style, computing an adjusted rating with mean and standard deviation, and extracting top and bottom beers using pandas.
Learn symbolic programming with the Python library SymPy to model physical systems, define variables and functions, derive and integrate, and numerically evaluate with Lambdify for Beer-lambert law and experimental design.
Model physical systems with sympy to simulate the Beer-Lambert law in a gas cell and estimate concentration from light absorption using alpha equals epsilon times c.
Showcases Beer-Lambert modeling with SymPy, loading ethanol molar absorption data, interpolating at 9.5 micrometers, and evaluating intensity decay across 0–10 m.
Learn to model light attenuation in absorbing media using the Beer-Lambert law with SymPy, estimate gas concentration from optical measurements, and perform curve fitting with SciPy to retrieve absorption coefficients.
Apply optimal experimental design to spectroscopy by choosing measurement points to improve concentration estimates via the Beer-Lambert law. Learn to implement the design using symbolic programming with SymPy.
Learn how Beer Lambert law models light attenuation in ethanol, estimate concentration from optical measurements, and explore how measurement positions affect parameter accuracy through curve fitting and noise.
Explore how the Fisher information matrix guides optimal measurement positions to improve gas concentration estimates and learn about model parameters I0 and alpha.
Explore how the Fisher information matrix informs the Cramér-Rao bound on parameter estimation, using classical measurement points and the Beer-Lambert law to bound concentration errors.
Optimize measurement positions by minimizing the Cramér-Rao bound via the Fisher information matrix. Compare classical uniform sampling to optimized points under the Beer-Lambert model.
Use the fisher information matrix to optimize sampling points, showing that measuring at the start and after about ten meters improves parameter estimates and gas concentration accuracy.
Choose discrete colors and color maps for line, scatter, and two-dimensional pseudo color plots, normalize data, and map sigma to colors for clear, accessible visuals.
Explore creating a custom color cycler to cycle line colors in a plot, specify hex colors, test colorblind accessibility, and choose palettes with color stucco for clear, color-safe visualizations.
Create a two-dimensional Gorshin distribution with a mesh grid and color map, then compare perceptually uniform maps like magma, jet, and turbo, noting artifacts and linearity.
Learn to reveal boundaries in data using divergent color maps for 1D and 2D plots, and highlight full width half maximum and full quarter maximum with contour levels.
Learn to create and apply a custom style sheet for your plots, specify default visuals, and load the custom style to update figures.
Create custom styles for plotting a Gaussian distribution by applying a style sheet, plotting five standard deviation curves, and updating axis labels, title, and grid settings.
Plot six clusters for scatter plots using normally distributed x and y data with margins. Set aspect ratio and customize style with a style sheet; explore histograms as density plots.
Create subtle color plots with custom styling by defining two-dimensional data, adjusting shading and color maps, and applying a custom style sheet to produce notebook, talk, and report plot presets.
Export graphics and post-process two-dimensional Gaussian visuals with Inkscape, merging figures for publication after generating mock data in Python and using regular grid interpolation for slices.
Clean and align figures in Inkscape, removing ticks and labels, matching axis colors, and exporting high-dpi PNGs with PowerPoint slide sizing.
"Python for Research and Scientific Computing" is a project-based course designed to improve your Python skills efficiently and make your research more insightful.
In this course, you learn to master powerful scientific Python tools like JupyterLab, NumPy, Matplotlib, SciPy, Pandas, and SymPy. Develop the ability to:
Implement advanced numerical techniques such as Monte Carlo simulations.
Numerically solve multidimensional and coupled differential equations.
Track and predict Brownian motion for insightful video analysis.
Estimate model parameters through optimization and curve fitting.
Conduct statistical analysis on extensive databases with millions of entries.
Design physical models with symbolic programming.
This practice-oriented course applies proven methods and best practices that will enable you to solve scientific challenges with confidence. Whether you're a professional in science, technology, engineering, or math (STEM) or an experienced researcher, you'll benefit from engaging coding projects that strengthen your problem-solving skills. Independent exercises help you to deepen your understanding and proficiency in applying Python to solve real-world scientific problems. Solutions are provided to support your progress every step of the way.
If you're a curious researcher or STEM professional with some knowledge of Python and advanced math, this course will help you apply those skills to real scientific problems. Sign up now and discover how Python can make your research more effective.