kt_grids_specified Module

Set up sets of (kx, ky) values for linear runs.



Contents


Variables

Type Visibility Attributes Name Initial
integer, private :: naky
integer, private :: ntheta0
integer, private :: nx
integer, private :: ny
logical, private :: initialized = .false.
type(kt_grids_specified_config_type), private :: kt_grids_specified_config
type(kt_grids_specified_element_config_type), private, dimension(:), allocatable :: kt_grids_specified_element_config

Derived Types

Used to represent the input configuration of kt_grids_specified

Components

Type Visibility Attributes Name Initial
logical, public :: exist = .false.

Does the related namelist exist in the target input file?

integer, public :: index = 0

Used to hold the specific index of numbered namelists

logical, public :: skip_read = .false.

Do we want to skip the read step in init?

logical, public :: skip_broadcast = .false.

Do we want to skip the broadcast step in init?

integer, public :: naky = 1

The number of ky values evolved. The total number of modes evolved is given by the maximum of naky and ntheta0. One must also set up the appropriate number of kt_grids_specified_element_<i> namelists.

integer, public :: ntheta0 = 1

The number of theta0 values evolved. The total number of modes evolved is given by the maximum of naky and ntheta0. One must also set up the appropriate number of kt_grids_specified_element_<i> namelists.

integer, public :: nx = 0

Mostly ignored. Does not set the number of modes used.

Read more…
integer, public :: ny = 0

Mostly ignored. Does not set the number of modes used.

Read more…

Type-Bound Procedures

procedure , public , :: is_initialised => is_initialised_generic Function
procedure , public , :: init => init_generic Subroutine
procedure , public , :: setup => setup_generic Subroutine
procedure , public , :: write_namelist_header Subroutine
procedure , public , :: get_name => get_name_generic Function
procedure , public , :: get_requires_index => get_requires_index_generic Function
procedure , public , nopass :: write_namelist_footer Subroutine
generic, public , :: write_key_val => write_key_val_string, write_key_val_real, write_key_val_complex, write_key_val_integer, write_key_val_logical, write_key_val_real_array, write_key_val_complex_array, write_key_val_integer_array
procedure , public :: read => read_kt_grids_specified_config Subroutine
procedure , public :: write => write_kt_grids_specified_config Subroutine
procedure , public :: reset => reset_kt_grids_specified_config Subroutine
procedure , public :: broadcast => broadcast_kt_grids_specified_config Subroutine
procedure , public , nopass :: get_default_name => get_default_name_kt_grids_specified_config Function
procedure , public , nopass :: get_default_requires_index => get_default_requires_index_kt_grids_specified_config Function

Used to represent the input configuration of a specific specified wavenumber pair

Components

Type Visibility Attributes Name Initial
logical, public :: exist = .false.

Does the related namelist exist in the target input file?

integer, public :: index = 0

Used to hold the specific index of numbered namelists

logical, public :: skip_read = .false.

Do we want to skip the read step in init?

logical, public :: skip_broadcast = .false.

Do we want to skip the broadcast step in init?

real, public :: aky = 0.4

Sets the value for this wavenumber element.

real, public :: akx = 0.0

Sets the value for this wavenumber element (but should set theta0 instead).

real, public :: theta0 = 0.0

Sets the value for this wavenumber element.

Type-Bound Procedures

procedure , public , :: is_initialised => is_initialised_generic Function
procedure , public , :: init => init_generic Subroutine
procedure , public , :: setup => setup_generic Subroutine
procedure , public , :: write_namelist_header Subroutine
procedure , public , :: get_name => get_name_generic Function
procedure , public , :: get_requires_index => get_requires_index_generic Function
procedure , public , nopass :: write_namelist_footer Subroutine
generic, public , :: write_key_val => write_key_val_string, write_key_val_real, write_key_val_complex, write_key_val_integer, write_key_val_logical, write_key_val_real_array, write_key_val_complex_array, write_key_val_integer_array
procedure , public :: read => read_kt_grids_specified_element_config Subroutine
procedure , public :: write => write_kt_grids_specified_element_config Subroutine
procedure , public :: reset => reset_kt_grids_specified_element_config Subroutine
procedure , public :: broadcast => broadcast_kt_grids_specified_element_config Subroutine
procedure , public , nopass :: get_default_name => get_default_name_kt_grids_specified_element_config Function
procedure , public , nopass :: get_default_requires_index => get_default_requires_index_kt_grids_specified_element_config Function

Functions

Get the module level config instance

Arguments

None

Return Value type(kt_grids_specified_config_type)

Get the module level config instance

Arguments

None

Return Value type(kt_grids_specified_element_config_type), allocatable, (:)

Gets the default name for this namelist

Arguments

None

Return Value character(len=CONFIG_MAX_NAME_LEN)

Gets the default requires index for this namelist

Arguments

None

Return Value logical

Gets the default name for this namelist

Arguments

None

Return Value character(len=CONFIG_MAX_NAME_LEN)

Gets the default requires index for this namelist

Arguments

None

Return Value logical


Subroutines

public subroutine init_kt_grids_specified(kt_grids_specified_config_in)

FIXME : Add documentation

Arguments

Type IntentOptional Attributes Name
type(kt_grids_specified_config_type), intent(in), optional :: kt_grids_specified_config_in

public subroutine finish_parameters_specified()

FIXME : Add documentation

Arguments

None

public subroutine wnml_kt_grids_specified(unit, aky, theta0)

FIXME : Add documentation

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: unit
real, intent(in), dimension(:) :: aky
real, intent(in), dimension(:,:) :: theta0

public subroutine specified_get_sizes(naky_x, ntheta0_x, nx_x, ny_x)

FIXME : Add documentation

Arguments

Type IntentOptional Attributes Name
integer, intent(out) :: naky_x
integer, intent(out) :: ntheta0_x
integer, intent(out) :: nx_x
integer, intent(out) :: ny_x

public subroutine specified_get_grids(aky, theta0, akx, ikx, kt_grids_specified_element_config_in)

FIXME : Add documentation

Read more…

Arguments

Type IntentOptional Attributes Name
real, intent(out), dimension (:) :: aky
real, intent(out), dimension (:,:) :: theta0
real, intent(out), dimension (:) :: akx
integer, intent(out), dimension (:) :: ikx

Discrete kx wavenumber grid indices

type(kt_grids_specified_element_config_type), intent(in), optional, dimension(:) :: kt_grids_specified_element_config_in

private subroutine read_element(i, aky_dummy, theta0_dummy, akx_dummy, kt_grids_specified_element_config_in)

FIXME : Add documentation

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: i
real, intent(out) :: aky_dummy
real, intent(out) :: theta0_dummy
real, intent(out) :: akx_dummy
type(kt_grids_specified_element_config_type), intent(in), optional, dimension(:) :: kt_grids_specified_element_config_in

public subroutine check_kt_grids_specified(report_unit, aky, theta0)

Arguments

Type IntentOptional Attributes Name
integer, intent(in) :: report_unit
real, intent(in), dimension (:) :: aky
real, intent(in), dimension (:) :: theta0

public subroutine set_kt_grids_specified_config(kt_grids_specified_config_in, kt_grids_specified_element_config_in)

Set the module level config types Will abort if the module has already been initialised to avoid inconsistencies.

Arguments

Type IntentOptional Attributes Name
type(kt_grids_specified_config_type), intent(in), optional :: kt_grids_specified_config_in
type(kt_grids_specified_element_config_type), intent(in), optional, dimension(:) :: kt_grids_specified_element_config_in

private subroutine read_kt_grids_specified_config(self)

Reads in the kt_grids_specified_parameters namelist and populates the member variables

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_config_type), intent(inout) :: self

private subroutine write_kt_grids_specified_config(self, unit)

Writes out a namelist representing the current state of the config object

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_config_type), intent(in) :: self
integer, intent(in), optional :: unit

private subroutine reset_kt_grids_specified_config(self)

Resets the config object to the initial empty state

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_config_type), intent(inout) :: self

private subroutine broadcast_kt_grids_specified_config(self)

Broadcasts all config parameters so object is populated identically on all processors

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_config_type), intent(inout) :: self

private subroutine read_kt_grids_specified_element_config(self)

Reads in the kt_grids_specified_element namelist and populates the member variables

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_element_config_type), intent(inout) :: self

private subroutine write_kt_grids_specified_element_config(self, unit)

Writes out a namelist representing the current state of the config object

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_element_config_type), intent(in) :: self
integer, intent(in), optional :: unit

private subroutine reset_kt_grids_specified_element_config(self)

Resets the config object to the initial empty state

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_element_config_type), intent(inout) :: self

Broadcasts all config parameters so object is populated identically on all processors

Arguments

Type IntentOptional Attributes Name
class(kt_grids_specified_element_config_type), intent(inout) :: self