# ch3f_formal scan import numpy as np memory 24 GB molecule ch3f_formal { 0 1 C 0.25160466 0.98410067 1.94565167 H 1.18286433 1.52462747 2.17343494 H -0.43639970 0.82443849 2.78972335 O -0.00153327 0.58776285 0.83025097 -- 0 1 C -0.56244537 -0.34039992 -1.72706564 H -1.10756910 0.42490431 -2.27413395 H -1.16271491 -1.24315384 -1.64431777 H 0.37939808 -0.55925290 -2.22422726 F 4 R 1 180 3 -70.20141 X 4 1 9 A 5 -39.48718 } R1_vals=np.arange(2,5.2,.2) print R1_vals A2_vals=range(90,190,10) table=Table(rows=['R','A'], cols=['E(Electrostatics)','E(Exchange)','E(Induction)','E(Dispersion)','E(Total Energy)']) set basis = cc-pvdz print_out("R A Elst Exch Ind Total\n") for R in R1_vals: ch3f_formal.R=R for A in A2_vals: ch3f_formal.A=A energy('sapt2+3',molecule=ch3f_formal) Eelst = get_variable('SAPT2+3 ELST ENERGY') Eexch = get_variable('SAPT2+3 EXCH ENERGY') Eind = get_variable('SAPT2+3 IND ENERGY') Edisp = get_variable('SAPT2+3 DISP ENERGY') ET = get_variable('SAPT2+3 TOTAL ENERGY') print("%f %f %f %f %f %f %f\n" %(R ,A ,Eelst, Eexch, Eind, Edisp, ET)) table[R][A] = [Eelst, Eexch, Eind,Edisp,ET] print(table)