42 REAL(KIND=8),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
h1 43 REAL(KIND=8),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
h2 44 REAL(KIND=8),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
h3 45 REAL(KIND=8),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
htot 48 TYPE(
coolist),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
l1 49 TYPE(
coolist),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
l2 50 TYPE(
coolist),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
l3 54 TYPE(
coolist),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
b1 55 TYPE(
coolist),
DIMENSION(:),
ALLOCATABLE,
PUBLIC ::
b2 61 REAL(KIND=8),
DIMENSION(:,:),
ALLOCATABLE,
PUBLIC ::
q1 62 REAL(KIND=8),
DIMENSION(:,:),
ALLOCATABLE,
PUBLIC ::
q2 66 REAL(KIND=8),
DIMENSION(:),
ALLOCATABLE ::
dumb_vec 67 REAL(KIND=8),
DIMENSION(:,:),
ALLOCATABLE ::
dumb_mat1 68 REAL(KIND=8),
DIMENSION(:,:),
ALLOCATABLE ::
dumb_mat2 69 REAL(KIND=8),
DIMENSION(:,:),
ALLOCATABLE ::
dumb_mat3 70 REAL(KIND=8),
DIMENSION(:,:),
ALLOCATABLE ::
dumb_mat4 89 INTEGER :: AllocStat,i,j,k,l
91 print*,
'Initializing the decomposition tensors...' 93 print*,
"Initializing the correlation matrices and tensors..." 95 print*,
"Computing the correlation integrated matrices and tensors..." 99 print*,
"Computing the H term..." 102 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 105 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 108 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 117 IF (
mode.ne.
'ures')
THEN 138 print*,
"Computing the L terms..." 140 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 177 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 183 print*,
"Computing the B terms..." 185 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 187 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 218 print*,
"Computing the M term..." 221 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 239 print*,
"Computing the Q terms..." 241 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 264 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 284 IF (allocstat /= 0) stop
"*** Not enough memory ! ***" 296 IF (allocstat /= 0) stop
"*** Problem to deallocate ! ***" 299 IF (allocstat /= 0) stop
"*** Problem to deallocate ! ***" 302 IF (allocstat /= 0) stop
"*** Problem to deallocate ! ***" type(coolist), dimension(:), allocatable, public lxy
Tensor holding the linear part of the resolved tendencies involving the unresolved variables...
The stochastic models parameters module.
integer ndim
Number of variables (dimension of the model)
subroutine, public add_matc_to_tensor4(i, j, src, dst)
Routine to add a matrix to a rank-4 tensor.
real(kind=8), dimension(:,:), allocatable, public corr_i_full
Covariance matrix of the unresolved variables (full version)
subroutine, public comp_corrint
Routine that actually compute or load the integrals.
real(kind=8), dimension(:,:), allocatable, public corrint
Matrix holding the integral of the correlation matrix.
The MTV tensors used to integrate the MTV model.
type(coolist), dimension(:), allocatable, public l2
Second linear tensor.
subroutine, public add_vec_jk_to_tensor(j, k, src, dst)
Routine to add a vector to a rank-3 tensor.
The resolved-unresolved components decomposition of the tensor.
real(kind=8), dimension(:), allocatable dumb_vec
Dummy vector.
subroutine, public sparse_mul4_with_mat_jl(coolist_ijkl, mat_jl, res)
Sparse multiplication of a rank-4 tensor coolist with a matrix : .
type(coolist4), dimension(:), allocatable, public mtot
Tensor for the cubic terms.
type(coolist), dimension(:), allocatable, public l1
First linear tensor.
subroutine, public coo_to_mat_i(i, src, dst)
Routine to convert a rank-3 tensor coolist component into a matrix.
type(coolist), dimension(:), allocatable, public lyy
Tensor holding the linear part of the unresolved tendencies involving the unresolved variables...
subroutine, public coo_to_mat_j(j, src, dst)
Routine to convert a rank-3 tensor coolist component into a matrix.
real(kind=8) function, public mat_trace(A)
real(kind=8) function, public mat_contract(A, B)
type(coolist), dimension(:), allocatable, public btot
Total quadratic tensor.
type(coolist), dimension(:), allocatable, public b2
Second quadratic tensor.
real(kind=8), dimension(:), allocatable, public htot
Total constant vector.
real(kind=8), dimension(:), allocatable, public h1
First constant vector.
subroutine, public add_matc_to_tensor(i, src, dst)
Routine to add a matrix to a rank-3 tensor.
Coordinate list. Type used to represent the sparse tensor.
type(coolist), dimension(:), allocatable, public ltot
Total linear tensor.
real(kind=8), dimension(:,:), allocatable dumb_mat3
Dummy matrix.
type(coolist4), dimension(:), allocatable, public corr2int
Tensor holding the integral of the correlation outer product with itself.
type(coolist), dimension(:), allocatable, public l3
Third linear tensor.
type(coolist), dimension(:), allocatable, public byxy
Tensor holding the quadratic part of the unresolved tendencies involving both resolved and unresolved...
real(kind=8), dimension(:,:), allocatable, public q2
Constant terms for the state-independent noise covariance matrix.
subroutine, public init_corrint
Subroutine to initialise the integrated matrices and tensors.
real(kind=8), dimension(:), allocatable, public h3
Third constant vector.
subroutine, public init_mtv_int_tensor
Subroutine to initialise the MTV tensor.
real(kind=8), dimension(:,:), allocatable, public inv_corr_i_full
Inverse of the covariance matrix of the unresolved variables (full version)
subroutine, public coo_to_mat_ik(src, dst)
Routine to convert a rank-3 tensor coolist component into a matrix with i and k indices.
real(kind=8), dimension(:,:), allocatable, public q1
Constant terms for the state-dependent noise covariance matrix.
subroutine, public add_to_tensor(src, dst)
Routine to add a rank-3 tensor to another one.
real(kind=8), dimension(:,:), allocatable dumb_mat4
Dummy matrix.
real(kind=8), dimension(:,:), allocatable dumb_mat1
Dummy matrix.
type(coolist), dimension(:), allocatable, public bxxy
Tensor holding the quadratic part of the resolved tendencies involving both resolved and unresolved v...
type(coolist), dimension(:), allocatable, public utot
Linear terms for the state-dependent noise covariance matrix.
4d coordinate list. Type used to represent the rank-4 sparse tensor.
subroutine, public matc_to_coo(src, dst)
Routine to convert a matrix to a rank-3 tensor.
subroutine, public sparse_mul3_with_mat(coolist_ijk, mat_jk, res)
Sparse multiplication of a rank-3 tensor coolist with a matrix: .
subroutine, public add_vec_ikl_to_tensor4(i, k, l, src, dst)
Routine to add a vector to a rank-4 tensor.
Module to initialize the correlation matrix of the unresolved variables.
type(coolist4), dimension(:), allocatable, public vtot
Quadratic terms for the state-dependent noise covariance matrix.
The model parameters module.
type(coolist), dimension(:), allocatable, public bxyy
Tensor holding the quadratic part of the resolved tendencies involving unresolved variables...
real(kind=8), dimension(:), allocatable, public h2
Second constant vector.
type(coolist), dimension(:), allocatable, public lyx
Tensor holding the linear part of the unresolved tendencies involving the resolved variables...
type(coolist), dimension(:), allocatable, public byxx
Tensor holding the quadratic part of the unresolved tendencies involving resolved variables...
character(len=4) mode
Stochastic mode parameter.
real(kind=8), dimension(:,:), allocatable dumb_mat2
Dummy matrix.
subroutine, public init_dec_tensor
Subroutine that initialize and compute the decomposed tensors.
Module to compute or load the integrals of the correlation matrices.
subroutine, public coo_to_vec_jk(j, k, src, dst)
Routine to convert a rank-3 tensor coolist component into a vector.
type(coolist), dimension(:), allocatable, public b1
First quadratic tensor.