Provides an abstract type to represent large masses of ice, such as ice sheets and ice shelves.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
character(len=12), | public, | parameter | :: | hdf_type_attr | = | 'glacier_type' |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(in) | :: | this |
The value of whatever property of the glacier is being returned.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(in) | :: | this |
The value of whatever property of the glacier is being returned.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(in) | :: | this | |||
class(glacier), | intent(in), | dimension(:) | :: | previous_states | The states of the glacier in the previous time steps. The first element of the array should be the most recent. The default implementation will only make use of the most recent state, but the fact that this is an array allows overriding methods to use older states for higher-order integration methods. |
|
class(scalar_field), | intent(in) | :: | melt_rate | Thickness of the ice above the glacier |
||
class(scalar_field), | intent(in) | :: | basal_drag_parameter | A paramter, e.g. coefficient of friction, needed to calculate the drag on basal surface of the glacier. |
||
real(kind=r8), | intent(in) | :: | water_density | The density of the water below the glacier |
The residual of the system of equations describing the glacier
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(inout) | :: | this | |||
class(glacier), | intent(in), | dimension(:) | :: | previous_states | The states of the glacier in the previous time steps. The first element of the array should be the most recent. The default implementation will only make use of the most recent state, but the fact that this is an array allows overriding methods to use older states for higher-order integration methods. |
|
class(scalar_field), | intent(in) | :: | melt_rate | Thickness of the ice above the glacier |
||
class(scalar_field), | intent(in) | :: | basal_drag_parameter | A paramter, e.g. coefficient of friction, needed to calculate the drag on basal surface of the glacier. |
||
real(kind=r8), | intent(in) | :: | water_density | The density of the water below the glacier |
||
real(kind=r8), | intent(in), | dimension(:) | :: | delta_state | The change to the state vector which is being preconditioned. |
The result of applying the preconditioner to delta_state
.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(in) | :: | this |
The state vector of the glacier
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(in) | :: | this |
The value of whatever property of the glacier is being returned.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(in) | :: | this |
A time step which will allow integration of the ice shelf without causing numerical instability.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(inout) | :: | this | |||
class(scalar_field), | intent(in) | :: | basal_drag | A paramter, e.g. coefficient of friction, needed to calculate the drag on basal surface of the glacier. |
||
logical, | intent(out) | :: | success | True if the integration is successful, false otherwise |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(inout) | :: | this | |||
real(kind=r8), | intent(in), | dimension(:) | :: | state_vector | A real array containing the data describing the state of the glacier. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(inout) | :: | this | |||
real(kind=r8), | intent(in) | :: | time | The time at which the glacier is in the present state. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(inout) | :: | this | |||
integer(kind=hid_t), | intent(in) | :: | file_id | The identifier for the HDF5 file/group from which the data will be read. |
||
character(len=*), | intent(in) | :: | group_name | The name of the group in the HDF5 file from which to read glacier's data. |
||
integer, | intent(out) | :: | error | Flag indicating whether routine ran without error. If no error occurs then has value 0. |
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(in) | :: | this | |||
integer(kind=hid_t), | intent(in) | :: | file_id | The identifier for the HDF5 file/group in which this data is meant to be written. |
||
character(len=*), | intent(in) | :: | group_name | The name to give the group in the HDF5 file storing the glacier's data. |
||
integer, | intent(out) | :: | error | Flag indicating whether routine ran without error. If no error occurs then has value 0. |
Abstract interface for function providing the glacier thickness when a concrete object is being instantiated.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=r8), | intent(in), | dimension(:) | :: | location | The position $\vec{x}$ at which to compute the thickness |
The thickness of the glacier at location
Abstract interface for function providing the glacier velocity when a concrete object is being instantiated.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
real(kind=r8), | intent(in), | dimension(:) | :: | location | The position $\vec{x}$ at which to compute the thickness |
The velocity vector of the ice in the glacier at location
An abstract data type which represents large masses of ice, such as ice shelves and ice sheets.
procedure(get_scalar), public :: ice_thickness | Returns the thickness of the ice in the glacier across the domain. |
procedure(get_r8), public :: ice_density | Returns the density of the ice, which is assumed to be uniform. |
procedure(get_r8), public :: ice_temperature | Returns the temperature of the ice, which is assumed to be uniform. |
procedure(get_residual), public :: residual | Computes the residual of the system of equations describing the glacier. |
procedure(precond), public :: precondition | Applies a preconditioner to the passed state vector. |
procedure(solve_vel), public :: solve_velocity | Solves for the velocity field using the current thickness. |
procedure(setter), public :: update | Sets the state of the glacier. |
procedure(time_setter), public :: set_time | Sets the time record for this glacier. |
procedure(get_i), public :: data_size | Returns the number of elements in the glacier's state vector |
procedure(get_r81d), public :: state_vector | Returns the glacier's state vector, a 1D array with all necessary data to describe its state. |
procedure(read_dat), public :: read_data | Read the glacier data from an HDF5 file on the disc. |
procedure(write_dat), public :: write_data | Writes the data describing the glacier to the disc as an HDF5 file. |
procedure(t_step), public :: time_step | Calculates the appropriate time step for integration. |
procedure(assign_ice), private :: assign | Copies the data from one glacier into another. This is only needed due to a bug in gfortran which means that the intrinsic assignment for glacier types is not using the appropriate defined assignment for the field components. |
generic, public :: assignment(=) => assign | |
procedure, public :: integrate => glacier_integrate | Performs a time-step of the integration, taking the state of the glacier to the specified time using the provided melt-rate data. |
procedure, public :: integrate_layers => glacier_integrate_layers | Dummy routine which can be over-ridden to integrate internal layers of the glacier to the specified time. |
Integrates the glacier's state to time
. This is done using the
NITSOL package of iterative Krylov solvers. If a different
algorithm for the integration is desired, then this method may
be overridden in the concrete implementations of the glacier
type.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(inout) | :: | this | |||
class(glacier), | intent(in), | dimension(:) | :: | old_states | Previous states of the glacier, with the most recent one first. |
|
class(scalar_field), | intent(in) | :: | basal_melt | The melt rate that the bottom of the glacier experiences during this time step. |
||
class(scalar_field), | intent(in) | :: | basal_drag | A paramter, e.g. coefficient of friction, needed to calculate the drag on basal surface of the glacier. |
||
real(kind=r8), | intent(in) | :: | water_density | The density of the water below the glacier. |
||
real(kind=r8), | intent(in) | :: | time | The time to which the glacier should be integrated |
||
logical, | intent(out) | :: | success | True if the integration is successful, false otherwise |
Dummy routine which does nothing.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
class(glacier), | intent(inout) | :: | this | |||
class(glacier), | intent(in), | dimension(:) | :: | old_states | Previous states of the glacier, with the most recent one first. |
|
real(kind=r8), | intent(in) | :: | time | The time to which the glacier should be integrated |
||
logical, | intent(out) | :: | success | True if the integration is successful, false otherwise |