mitgcm
Analysis of MITgcm output using python
|
A tracer point field that contains methods for density fields. More...
Public Member Functions | |
def | __init__ |
def | calculate_density |
Cacluate Density field given temperature and salinity fields, using the linear equation of state. More... | |
def | calculate_TotRhoTend (self, model_instance) |
Calculate time rate of change of the Density field from the temperature tendency and the linear equation of state. More... | |
Public Member Functions inherited from mitgcm.core.Tracerpoint_field | |
def | __init__ |
def | load_field |
Load a model field from NetCDF output. More... | |
def | take_d_dx |
Take the x derivative of the field on tracer points, using spacings in grid object. More... | |
def | numerics_take_d_dx (self, rho, wet_mask_TH, dxC) |
def | take_d_dy |
Take the y derivative of the field on tracer points, using spacings in grid object. More... | |
def | numerics_take_d_dy (self, rho, wet_mask_TH, dyC) |
The numerical bit of taking the y derivative. More... | |
def | take_d_dz |
Take the z derivative of the field given on tracer-points, using the spacings in grid object. More... | |
Public Member Functions inherited from mitgcm.core.MITgcm_Simulation | |
def | __init__ |
Instantiate an MITgcm model instance. More... | |
def | load_field |
Load a model field from NetCDF output. More... | |
def | load_from_file (self, model_instance, file_list, variable, time_level, grid_loc, single_file) |
Internal function to pull the data from the file(s). More... | |
def | __add__ (self, other) |
A method that allows model objects to be added together. More... | |
def | __div__ (self, other) |
A method that allows model objects to be divided by floating point numbers. More... | |
def | __mul__ (self, other) |
A method that allows model objects to be multiplied by floating point numbers. More... | |
def | __rmul__ (self, other) |
A method that allows model objects to be multiplied by floating point numbers. More... | |
Additional Inherited Members | |
Public Attributes inherited from mitgcm.core.MITgcm_Simulation | |
grid | |
A tracer point field that contains methods for density fields.
Only linear equation of state with temperature variations is supported at the moment.
The linear equation of state is given by
\[ \rho = \rho_{nil} (-\alpha_{T} (\theta - \theta_{0}) + \beta_{S} (S - S_{0})) + \rho_{nil} \]
where \( \rho_{nil} \) is the reference density, \( \alpha_{T} \) is the thermal expansion coefficient, \( \beta_{S} \) is the haline contraction coefficient, \( \theta \) and \( \beta \) are the temperature and salinity fields, and subscript zeros denote reference values.
def mitgcm.core.Density.__init__ | ( | self, | |
model_instance, | |||
Talpha = 2e-4 , |
|||
Sbeta = 0 , |
|||
RhoNil = 1035 , |
|||
cp = 4000 , |
|||
temp_field = 'THETA' , |
|||
salt_field = 'S' , |
|||
density_field = 'RHO' , |
|||
Tref = 20 , |
|||
Sref = 30 , |
|||
empty = False |
|||
) |
def mitgcm.core.Density.calculate_density | ( | self, | |
model_instance, | |||
Talpha = 2e-4 , |
|||
Sbeta = 0 , |
|||
RhoNil = 1035 , |
|||
cp = 4000 , |
|||
temp_field = 'THETA' , |
|||
salt_field = 'S' , |
|||
density_field = 'RHO' , |
|||
Tref = 20 , |
|||
Sref = 30 |
|||
) |
def mitgcm.core.Density.calculate_TotRhoTend | ( | self, | |
model_instance | |||
) |
Calculate time rate of change of the Density field from the temperature tendency and the linear equation of state.
Returned as 'TotRhoTend' associated with the density object.
Differentiating the linear equation of state with respect to temperature, and assuming \( \beta_{S} \) equals zero, gives
\[ \frac{\partial \rho}{\partial t} = - \rho_{nil} \alpha_{T} \frac{\partial \theta}{\partial t} \]