Writing and Reading#

This part shows how to write and read files with rgmol.

Writing and reading eigenmodes#

After the computation of the eigenmodes of a kernel, the eigenmodes will be saved by default.

The molecule.plot_diagonalized_kernel will also look if the eigenmodes have already been calculated.

In order to recompute the eigenmodes, one can use the try_reading keyword. And if one do not want to save the eigenmodes, one can use the save keyword.

More information on the keywords can be found here.

They will be saved in the rgmol folder see here for more information.

Writing cube files#

One can use the method molecule.write_cube to write a cube file containing a certain vector.

This file can then be reextracted using the rgmol.extract_cube.extract or rgmol.extract_cube.extract functions.