getmoms_gryfx_c Subroutine

private subroutine getmoms_gryfx_c(dens_ky0, upar_ky0, tpar_ky0, tprp_ky0, qpar_ky0, qprp_ky0, phi_ky0) bind(c, name='getmoms_gryfx')

FIXME : Add documentation

Arguments

Type IntentOptional Attributes Name
complex(kind=c_float_complex), intent(inout) :: dens_ky0(naky*ntheta0*2*ntgrid*nspec)
complex(kind=c_float_complex), intent(inout) :: upar_ky0(naky*ntheta0*2*ntgrid*nspec)
complex(kind=c_float_complex), intent(inout) :: tpar_ky0(naky*ntheta0*2*ntgrid*nspec)
complex(kind=c_float_complex), intent(inout) :: tprp_ky0(naky*ntheta0*2*ntgrid*nspec)
complex(kind=c_float_complex), intent(inout) :: qpar_ky0(naky*ntheta0*2*ntgrid*nspec)
complex(kind=c_float_complex), intent(inout) :: qprp_ky0(naky*ntheta0*2*ntgrid*nspec)
complex(kind=c_float_complex), intent(out) :: phi_ky0(naky*ntheta0*2*ntgrid)

Contents

Source Code


Source Code

  subroutine getmoms_gryfx_c (dens_ky0, upar_ky0, tpar_ky0, tprp_ky0, &
       qpar_ky0, qprp_ky0, phi_ky0) &
       bind(c, name='getmoms_gryfx')
    use dist_fn, only: getmoms_gryfx_dist
    use theta_grid, only: ntgrid
    use kt_grids, only: ntheta0, naky
    use species, only: nspec
    use iso_c_binding
    implicit none
    complex (c_float_complex), intent (inout) :: & 
         dens_ky0(naky*ntheta0*2*ntgrid*nspec)
    complex (c_float_complex), intent (inout) :: & 
         upar_ky0(naky*ntheta0*2*ntgrid*nspec)
    complex (c_float_complex), intent (inout) :: & 
         tpar_ky0(naky*ntheta0*2*ntgrid*nspec)
    complex (c_float_complex), intent (inout) :: & 
         tprp_ky0(naky*ntheta0*2*ntgrid*nspec)
    complex (c_float_complex), intent (inout) :: & 
         qpar_ky0(naky*ntheta0*2*ntgrid*nspec)
    complex (c_float_complex), intent (inout) :: & 
         qprp_ky0(naky*ntheta0*2*ntgrid*nspec)
    complex (c_float_complex), intent (out) :: phi_ky0(naky*ntheta0*2*ntgrid)

    call getmoms_gryfx_dist(dens_ky0, upar_ky0, tpar_ky0, &
         tprp_ky0, qpar_ky0, qprp_ky0, phi_ky0)

    call interpolate_theta(gs2_2_gryfx_grid, dens_ky0, .false.)
    call interpolate_theta(gs2_2_gryfx_grid, upar_ky0, .false.)
    call interpolate_theta(gs2_2_gryfx_grid, tpar_ky0, .false.)
    call interpolate_theta(gs2_2_gryfx_grid, tprp_ky0, .false.)
    call interpolate_theta(gs2_2_gryfx_grid, qpar_ky0, .false.)
    call interpolate_theta(gs2_2_gryfx_grid, qprp_ky0, .false.)
    call interpolate_theta(gs2_2_gryfx_grid, phi_ky0, .true.)
  end subroutine getmoms_gryfx_c