Skip to content

A clean Jupyter notebook demonstrating how to construct and visualise reaction free-energy profiles (ΔG) using Python, NumPy, and Matplotlib. Includes examples of two-path, branched, and three-way cheletropic/Diels–Alder mechanistic pathways, with Hartree-to-kJ/mol conversion, safety checks, smoothing functions, and publication-quality figures.

License

Notifications You must be signed in to change notification settings

Squiddy101/Reaction-Energy-Profiles-Python

Repository files navigation

Reaction Energy Profiles in Python

This repository contains a clean, research-ready Jupyter notebook for plotting reaction free-energy profiles using Python.
It was developed to support computational chemistry coursework and to visualise reaction coordinate diagrams generated from ab initio and semi-empirical methods (e.g., PM6, B3LYP/6-31G(d)).

The notebook demonstrates how to convert Hartree energies → kJ mol⁻¹, construct relative ΔG diagrams, apply smooth cubic interpolation, and produce publication-quality figures for mechanistic analysis.


🔍 What this notebook shows

✓ Two-way, same direction

Comparison of two electronic-structure methods (e.g., PM6 vs DFT) along a single reaction path.

✓ Two-way, two directions

One reactant branching into two competing pathways (left vs right), showing activation barriers and reaction free energies for each path.

✓ Three-way, two directions (cheletropic vs Diels–Alder)

Mechanistic comparison of three competing channels, including endo/exo selectivity and cheletropic behaviour.

All examples use relative free energies (ΔG) and are written for a computational / physical chemistry audience.


📁 Files

  • Reaction_Profile_Tutorial.ipynb
    Main notebook containing:
    • safety-checked energy input
    • smooth cubic interpolation helper (smooth_profile)
    • clean, labelled Matplotlib plots
    • three full reaction-profile examples
    • optional high-resolution plt.savefig() lines

⚙️ Installation & Requirements

Install dependencies:

pip install -r requirements.txt

🧪 Scientific context

The notebook uses Hartree energies exported from Gaussian calculations and converts them to kJ mol⁻¹ using:

1 Eh ≈ 2625.5 kJ mol⁻¹

Figures illustrate:

  • ΔG‡ (activation free energy)
  • ΔGᵣ (reaction free energy)
  • labelled stationary points (reactants, transition states, products)
  • smooth reaction-coordinate curves for clear visual comparison

The plotting style is intentionally minimalistic and suitable for reports, lab write-ups, dissertations, and publications.


📜 License

This project is released under the MIT License, allowing reuse for teaching, research, or personal work.

About

A clean Jupyter notebook demonstrating how to construct and visualise reaction free-energy profiles (ΔG) using Python, NumPy, and Matplotlib. Includes examples of two-path, branched, and three-way cheletropic/Diels–Alder mechanistic pathways, with Hartree-to-kJ/mol conversion, safety checks, smoothing functions, and publication-quality figures.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published