S = (facz/dd20)
S = facz*S !raise to the Npowerloc+1
S = exp(facz/dd)-one
S =facz-dd
IF( (facz.GE.dd).AND.(facz.LT.dd20) ) THEN
plumek(i) = max(zero,two*So*facz-S)
& three*So*facz - three*So*So*facz*facz + S)
S = facz*S !raise to the Npower+1
plumek(i) = max(zero,two/dd20*facz-S/So)
& three/dd20*facz - three/(dd20*dd20)*facz*facz + S/So)
_RL facz, dd, dd20
facz = abs(fact*plumek(i))
IF (SPDepth(i).GE.facz .and. SPDepth(i) .GT. zero) THEN
facz = fact*swdk(i)
IF ( facz .LT. -200. _d 0 ) THEN
swdk(i) = rfac(jwtype) * exp( facz/a1(jwtype) )
& + (1. _d 0 - rfac(jwtype)) * exp( facz/a2(jwtype) )
_RL facz