📄 text1.f90
字号:
call ess(m1,m2,m3,espx1,espx2,espy1,espy2)
call ess(m1,m2,m4,essx1,essx2,essy1,essy2)
esx1=esx1+x(j)*(espx1-essx1)
esx2=esx2+x(j)*(espx2-essx2)
esy1=esy1+x(j)*(espy1-essy1)
esy2=esy2+x(j)*(espy2-essy2)
subroutine ess(point1,point2,point3,es11,es12,es21,es22)
implicit none
real(8):: point1(3),point2(3),point3(3)
! real(8):: !angle
complex(8):: es11,es12,es21,es22
real dot
real(8),parameter::waveimped=120.0*3.1415926
real(8),parameter::PI=3.141592653589793
real(8):: kk
common /boshu/kk
real temp1,temp2,temp3 !Ax,Ay,Az !临时变量:磁矢势x,y,z分量
complex(8):: mer
! real(8) es(3) !临时变量
real rc(3)!temp1,temp2,temp3 !临时变量
real rn(3)!tempx,tempy,tempz !临时变量
real rs(3) ,thets(3), phis(3)
real thetas, phais, thesin, thecos, phaisin, phaicos
complex(8):: jj
integer i
jj=dcmplx(0.,1.)
do i=1,3
rc(i)=(point1(i)+point2(i)+point3(i))/3.0
rn(i)=(point1(i)+point2(i)+point3(i))/3.0-point3(i)
enddo
thesin=sin(thetas)
thecos=cos(thetas)
phaisin=sin(phais)
phaicos=cos(phais)
rs(1)=thesin*phaicos
rs(2)=thesin*phaisin
rs(3)=thecos
thets(1)=thecos*phaicos
thets(2)=thecos*phaisin
thets(3)=-thesin
phis(1)=-phaisin
phis(2)= phaicos
phis(3)= 0.0
!先计算xz平面的远区散射
phais=0
do i=0,180
thetas=float(i)*2*pi/360
temp1=dot(rs,rc)
mer=0.5*jj*exp(i*kk*temp1)
temp2=dot(thets,rn)
temp3=dot(phis,rn)
es11=mer*temp2
es12=mer*temp3
enddo
!再计算yz平面的远区散射
phais=90
do i=0,180
thetas=float(i)*2*pi/360
temp1=dot(rs,rc)
mer=0.5*jj*exp(i*kk*temp1)
temp2=dot(thets,rn)
temp3=dot(phis,rn)
es21=mer*temp2
es22=mer*temp3
enddo
end
function dot(x,y)
implicit none
real dot,y(3),x(3)
dot=x(1)*y(1)+x(2)*y(2)+x(3)*y(3)
return
end
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -