设He原子的两个核外电子的轨道分别是
He原子的基态能级为
其中a0是半径,让a0由0.2增加到2.2步长是0.01,看看a0的变化对E有什么影响
得到的数据画成图
当a0=1.19时,E取最小值,E=-2.8476
当a0<0.59时,E为正,a0越小E越大
仅当a0=1时,动能/势能=-0.5,此时E=-2.75
随着a0的增加,动能和相互作用能都在减小,势能增加
He原子的基态能级为-2.90,这个方法得到的计算数值是实验值的98.19%。
对比前述用类氢轨道得到的-2.75(94.8%)计算精度提高了3.37%。
import csv
import sympy
import math
from sympy import symbols, cancel, Li
a = sympy.Symbol('a')
e = sympy.Symbol('e')
m = sympy.Symbol('m')
h = sympy.Symbol('h')
l = sympy.Symbol('l')
lp = sympy.Symbol('lp')
r = sympy.Symbol('r')
EE = sympy.Symbol('EE')
r1 = sympy.Symbol('r1')
r2 = sympy.Symbol('r2')
r3 = sympy.Symbol('r3')
a0 = sympy.Symbol('a0')
x = sympy.Symbol('x')
y = sympy.Symbol('y')
z = sympy.Symbol('z')
θ1= sympy.Symbol('θ1')
θ2= sympy.Symbol('θ2')
Φ1= sympy.Symbol('Φ1')
Φ2= sympy.Symbol('Φ2')
θ= sympy.Symbol('θ')
Ψ= sympy.Symbol('Ψ')
Φ= sympy.Symbol('Φ')
pi=sympy.Symbol('pi')
E=sympy.Symbol('E')
I=sympy.Symbol('I')
sin=sympy.Symbol('sin')
cos=sympy.Symbol('cos')
diff=sympy.Symbol('diff')
integrate=sympy.Symbol('integrate')
pi=sympy.pi
E=sympy.E
sin=sympy.sin
cos=sympy.cos
diff=sympy.diff
integrate=sympy.integrate
def jin (fr1 ,fr2 ):
f21 = fr1 * fr2 * (1 / r1) * fr1 * fr2 * r1 * r1 * r2 * r2
f22 = fr1 * fr2 * (1 / r2) * fr1 * fr2 * r1 * r1 * r2 * r2
f23 = (integrate(f21, (r2, 0, r1)))
f24 = (integrate(f22, (r2, r1, float('inf'))))
f25 = (16 * pi ** (2) * integrate(f24 + f23, (r1, 0, float('inf'))))
# print("f23",f23)
# print("f24",f24)
print("J", f25)
return f25
def hin( fx1 ,fx2, z ):
fx = fx1
z=z
# 拉普拉斯算符
f1 = (1 / (r * r)) * diff((r * r * diff(fx, r)), r)
f2 = (1 / (r * r * sin(θ))) * diff((sin(θ) * diff(fx, θ)), θ)
f3 = (1 / (r * r * sin(θ) * sin(θ))) * diff(fx, Φ, Φ)
f8 = fx2*(-1 / 2) * (f1 + f2 + f3)
# print ( f1 )
# print ( f2 )
# print ( f3 )
#print ( f8 )
# 球坐标积分 动能
f9 = (integrate((integrate(integrate(f8 * r * r * sin(θ), (r, 0, float('inf'))), (θ, 0, pi))), (Φ, 0, 2 * pi)))
print(f9)
f10 = fx2 * (-z / r) * fx
# 势能
#print(f10)
f11 = (integrate((integrate(integrate(f10 * r * r * sin(θ), (r, 0, float('inf'))), (θ, 0, pi))), (Φ, 0, 2 * pi)))
print(f11)
print("H", f9 + f11)
d=f9+f11
str=f9,f11,d
return str
z=2.0
f = open('d:/工业/f/naf3数据处理.csv','w',encoding='gbk')
csv_writer = csv.writer(f)
for i in range(1,200):
a0=0.2+i*0.01
fx1 = (z / a0) ** (1.5) * 2 * sympy.exp(-z * r / a0) * (4 * pi) ** (-0.5)
fr1=(z/a0)**(1.5)*2*sympy.exp(-z*r1/a0 )*(4*pi)**(-0.5)
fr2=(z/a0)**(1.5)*2*sympy.exp(-z*r2/a0 )*(4*pi)**(-0.5)
d2=jin(fr1, fr2)
d = hin(fx1, fx1, z)
print(" i ", i ," ",a0," ",d ," ",d2)
csv_writer.writerow([ a0 ,d ,d2])
# 5. 关闭文件
f.close()