modbuild_sp_model_template.h File Reference

#include "cta.h"
#include "f_cta_utils.h"

Go to the source code of this file.

Defines

#define CREATEFUNC_F77   CF77_CALL(usr_createfunc,USR_CREATEFUNC)

Functions

void usr_create (CTA_Handle *hinput, CTA_TreeVector *state, CTA_TreeVector *sbound, CTA_TreeVector *sparam, int *nnoise, CTA_Time *time0, CTA_String *snamnoise, CTA_Handle *husrdata, int *ierr)
 Creates a new model instance This routine creates and initialises a new model instance.
void usr_compute (CTA_Time *timespan, CTA_TreeVector *state, CTA_TreeVector *saxpyforc, int *baddnoise, CTA_TreeVector *sparam, CTA_Handle *husrdata, int *ierr)
 Compute timestep(s) This routine is computes several timesteps over a giving timespan.
void usr_covar (CTA_TreeVector *colsvar, int *nnoise, CTA_Handle *husrdata, int *ierr)
 Return the root of noise covariance matrix This routine is responsible for returning the covariance matrix of the noise parameters.
void usr_obs (CTA_TreeVector *state, CTA_ObsDescr *hdescr, CTA_Vector *vval, CTA_Handle *husrdata, int *ierr)
 Return values that correspond to observed values This routine is responsible for the transformation of the state-vector to the observations.
void usr_obssel (CTA_TreeVector *state, CTA_Time *ttime, CTA_ObsDescr *hdescr, CTA_String *sselect, CTA_Handle *husrdata, int *ierr)
 Select criterion for observations that can be used for the model. This routine is responsible for producing a selection criterion that will filter out all invalid observations. Invalid observations are observations for which the model cannot produce a corresponding value. For example observations that are outside the computational domain.
void usr_SP_Model_CreateFunc ()
void CREATEFUNC_F77 ()

Define Documentation

#define CREATEFUNC_F77   CF77_CALL(usr_createfunc,USR_CREATEFUNC)

Definition at line 32 of file modbuild_sp_model_template.h.


Function Documentation

void CREATEFUNC_F77 (  ) 

Definition at line 120 of file modbuild_sp_model_template.h.

void usr_compute ( CTA_Time timespan,
CTA_TreeVector state,
CTA_TreeVector saxpyforc,
int *  baddnoise,
CTA_TreeVector sparam,
CTA_Handle husrdata,
int *  ierr 
)

Compute timestep(s) This routine is computes several timesteps over a giving timespan.

Parameters:
timespan I Timespan to simulate
state IO State vector
saxpyforc I Offset on models forcings
baddnoise I flag (CTA_TRUE/CTA_FALSE) whether to add noise
sparam I Model parameters
husrdata IO Instance specific data
ierr O Return flag CTA_OK if successful

Referenced by usr_SP_Model_CreateFunc().

void usr_covar ( CTA_TreeVector colsvar,
int *  nnoise,
CTA_Handle husrdata,
int *  ierr 
)

Return the root of noise covariance matrix This routine is responsible for returning the covariance matrix of the noise parameters.

Parameters:
colsvar O Covariance of noise parameters array of noise. Represented als an array (nnoise) of tree-vectors. Note the sub-tree-vectors are already allocated.
nnoise I Number of noise parameters
husrdata IO Instance specific data
ierr O Return flag CTA_OK if successful

Referenced by usr_SP_Model_CreateFunc().

void usr_create ( CTA_Handle hinput,
CTA_TreeVector state,
CTA_TreeVector sbound,
CTA_TreeVector sparam,
int *  nnoise,
CTA_Time time0,
CTA_String snamnoise,
CTA_Handle husrdata,
int *  ierr 
)

Creates a new model instance This routine creates and initialises a new model instance.

Parameters:
hinput I Model configuration CTA_Tree of CTA_String
state O Model state (initialized to initial value. Note this statevector must be created
sbound O State-vector for the offset on the forcings. Set CTA_NULL if not used. Note this statevector must be created
nnoise O The number of noise parameters in model state. Set 0 in case of a deterministic model
time0 O Time instance of the initial state state. The time object is already created
snamnoise O Name of the substate containing the noise parameters. The string is already created
husrdata O Handle that can be used for storing instance specific data
ierr O Return flag CTA_OK if successful

Referenced by usr_SP_Model_CreateFunc().

void usr_obs ( CTA_TreeVector state,
CTA_ObsDescr hdescr,
CTA_Vector vval,
CTA_Handle husrdata,
int *  ierr 
)

Return values that correspond to observed values This routine is responsible for the transformation of the state-vector to the observations.

Parameters:
state I state vector
hdescr I Observation description of observations
vval O Model (state) values corresponding to observations in hdescr
husrdata IO Instance specific data
ierr O Return flag CTA_OK if successful

Referenced by usr_SP_Model_CreateFunc().

void usr_obssel ( CTA_TreeVector state,
CTA_Time ttime,
CTA_ObsDescr hdescr,
CTA_String sselect,
CTA_Handle husrdata,
int *  ierr 
)

Select criterion for observations that can be used for the model. This routine is responsible for producing a selection criterion that will filter out all invalid observations. Invalid observations are observations for which the model cannot produce a corresponding value. For example observations that are outside the computational domain.

Parameters:
state I state vector
ttime I timespan for selection
hdescr I observation description of all available observations
sselect O The select criterion to filter out all invalid observations
husrdata IO Instance specific data
ierr O Return flag CTA_OK if successful

Referenced by usr_SP_Model_CreateFunc().

void usr_SP_Model_CreateFunc (  ) 

Generated on 4 Mar 2014 for OpenDA by  doxygen 1.6.1