PSI_ROT_exp Function

public function PSI_ROT_exp(R, R0, sigR, Z, Z0, sigZ, theta)

Arguments

Type IntentOptional AttributesName
real(kind=rp), intent(in) :: R

R-coordinate of MH sampled location

real(kind=rp), intent(in) :: R0

R-coordinate of center of 2D Gaussian

real(kind=rp), intent(in) :: sigR

Variance of first dimension of 2D Gaussian

real(kind=rp), intent(in) :: Z

Z-coordinate of MH sampled location

real(kind=rp), intent(in) :: Z0

Z-coordinate of center of 2D Gaussian

real(kind=rp), intent(in) :: sigZ

Variance of second dimension of 2D Gaussian

real(kind=rp), intent(in) :: theta

Angle of counter-clockwise rotation (in radians), of 2D Gaussian distribution relative to R,Z

Return Value real(kind=rp)

Argument of exponential comprising 2D Gaussian distribution


Called by

proc~~psi_rot_exp~~CalledByGraph proc~psi_rot_exp PSI_ROT_exp proc~sample_hollmann_distribution_3d sample_Hollmann_distribution_3D proc~sample_hollmann_distribution_3d->proc~psi_rot_exp proc~get_hollmann_distribution_3d get_Hollmann_distribution_3D proc~get_hollmann_distribution_3d->proc~sample_hollmann_distribution_3d

Contents

Source Code


Source Code

FUNCTION PSI_ROT_exp(R,R0,sigR,Z,Z0,sigZ,theta)
  REAL(rp), INTENT(IN) 	:: R
  !! R-coordinate of MH sampled location
  REAL(rp), INTENT(IN) 	:: R0
  !! R-coordinate of center of 2D Gaussian
  REAL(rp), INTENT(IN) 	:: sigR
  !! Variance of first dimension of 2D Gaussian
  REAL(rp), INTENT(IN) 	:: Z
  !! Z-coordinate of MH sampled location
  REAL(rp), INTENT(IN) 	:: Z0
  !! Z-coordinate of center of 2D Gaussian
  REAL(rp), INTENT(IN) 	:: sigZ
  !! Variance of second dimension of 2D Gaussian
  REAL(rp), INTENT(IN) 	:: theta
  !! Angle of counter-clockwise rotation (in radians), of 2D Gaussian
  !! distribution relative to R,Z
  REAL(rp) 		:: PSI_ROT_exp
  !! Argument of exponential comprising 2D Gaussian distribution 

  PSI_ROT_exp=(R-R0)**2*((cos(theta))**2/(2*sigR**2)+ &
       (sin(theta))**2/(2*sigZ**2))+ &
       2*(R-R0)*(Z-Z0)*cos(theta)*sin(theta)*(1/(2*sigR**2)-1/(2*sigZ**2))+ &
       (Z-Z0)**2*((sin(theta))**2/(2*sigR**2)+(cos(theta))**2/(2*sigZ**2))
  
END FUNCTION PSI_ROT_exp