Hi all,
I have been using psi4 and Blender for a while to generate animations, and I think that these are simple and fun enough for other students to get some value out of them.
You can find the scripts here: GitHub - MaxParadiz/AnimateMolecularVibrations: Generate normal modes using Psi4, and then visualize the vibrations in Blender
The workflow consists of running two scripts:
- A psi4 python script that calculates the normal modes and saves them into a dictionary
- A blender script that should be run from within’s Blender python console. This script loads the data, generates the van-der-waals sphere representation of the molecule, and provides you with a “Vibrate()” function.
The Vibrate() function is where it gets more fun… Most molecular viewers will allow you to click on each vibration to visualize the mode. But this constraint does not exist here!
The Vibrate() function takes in as arguments lists of modes, amplitudes, and phases. This allows you to generate animations of superposition of modes, to create more organically-looking animations about molecular motion, visualize at how different modes might interact anharmonically, or use a boltzmann-weighted array to get an idea of the “average” molecule’s motion. It is pretty fun to play with.
I also have a script that uses Psi4 and Blender to generate molecular orbital transitions. This one I need to polish, and it is a bit less accessible, but if anyone would like to look at it to get some inspiration you can check it out here: GitHub - MaxParadiz/MOT: Animate molecular orbital transitions using Psi4 and Blender