Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(KORC_PARAMS), | intent(in) | :: | params | |||
real(kind=rp), | intent(in) | :: | v |
function CB_ei(params,v)
TYPE(KORC_PARAMS), INTENT(IN) :: params
REAL(rp), INTENT(IN) :: v
REAL(rp) :: CB_ei
REAL(rp) :: CB_ei_temp
REAL(rp) :: x
INTEGER :: i
x = v/cparams_ss%VTe
if ((.not.cparams_ms%LargeCollisions).or. &
(.not.(cparams_ss%P%ne_profile(1:6).eq.'RE-EVO'))) then
CB_ei = (0.5_rp*cparams_ss%Gammac/v)*(cparams_ss%Zeff* &
CLogei(v,cparams_ss%ne,cparams_ss%Te)/ &
CLogee(v,cparams_ss%ne,cparams_ss%Te))
else
CB_ei = (0.5_rp*cparams_ms%Gammac_min/v)*(cparams_ss%Zeff* &
CLogei(v,cparams_ss%P%n_ne,cparams_ss%Te)/ &
CLogee(v,cparams_ss%P%n_ne,cparams_ss%Te))
end if
if (params%bound_electron_model.eq.'HESSLOW') then
CB_ei_temp=CB_ei
do i=1,cparams_ms%num_impurity_species
if ((.not.cparams_ms%LargeCollisions).or. &
(.not.(cparams_ss%P%ne_profile(1:6).eq.'RE-EVO'))) then
CB_ei_temp=CB_ei_temp+CB_ei*cparams_ms%nz(i)/(cparams_ms%ne* &
cparams_ss%Zeff*CLogei(v,cparams_ss%ne,cparams_ss%Te))* &
g_j(i,v)
else
CB_ei_temp=CB_ei_temp+CB_ei*cparams_ms%nz(i)/(cparams_ms%ne* &
cparams_ss%Zeff*CLogei(v,cparams_ss%P%n_ne,cparams_ss%Te))* &
g_j(i,v)
end if
end do
CB_ei=CB_ei_temp
else if (params%bound_electron_model.eq.'ROSENBLUTH') then
CB_ei_temp=CB_ei
do i=1,cparams_ms%num_impurity_species
CB_ei_temp=CB_ei_temp+CB_ei*cparams_ms%nz(i)/cparams_ms%ne* &
(cparams_ms%Zo(i)-cparams_ms%Zj(i))/2._rp
end do
CB_ei=CB_ei_temp
end if
end function CB_ei