Name

PROPAG_CAL_LM — Function to calibrate routing models with a split sample test using lsqrsolve

Calling Sequence

[X,CR,[CRlog,CRrac,CALC]]=PROPAG_CAL_LM(Qdo,Qup,TS,PRopt,[ICAL,TSini,DEBFIN,FOBJ,XFIX])

Parameters

Qdo

Downstream discharge data (matrix [Nx1] where N is the number of time steps)

Qup

Upstream discharge data (matrix [Nx1] where N is the number of time steps)

TS

Time step length in hours (default = 24)

PRopt

Options to select different routing models (see c_PROPAG)

ICAL

Indices of the value to use in the Q vector during the calibration process. Default = find(Q>=0) (for example, if ICAL=[1,2] only the 2 first time steps are used for calibration)

TSini

Number of time-steps required for model initialisation (default = 30*24/TS)

DEBFIN

Delimitation of the 2 sub-periods in the dataset (periods including the intialisation of length TSini). DEBFIN should be filled in the following way: [[Beg. of P1 ; End of P1], [Beg. of P2; End of P2]]

FOBJ

Transformation applied to calculate the objective function (default = 'Q', possible = 'logQ' - logarithm transform - or 'racQ' -square root transform -)

XFIX

Values of fixed parameters, i.e. parameters set to constant values during the calibration process (matrix [4x1]). To calibrate some paramaters and fix others, use the %nan value in XFIX (Ex. [1.5;%nan;100;1.5] allows only the second parameter to be calibrated).

X

Optimised parameters for the 2 subperiods (matrix [4x2])

CR

Numerical quality criteria on each sub-period in calibration mode and on a cross-validation mode (matrix [5x4], see CRIT)

CRlog

Numerical quality criteria on each sub-period in calibration mode and on a cross-validation mode (matrix [5x4], see CRIT)

CRrac

Numerical quality criteria on each sub-period in calibration mode and on a cross-validation mode (matrix [5x4], see CRIT)

CALC

Calculated downstream streamflow time-series (matrix [Nx2], first column = calibrated data on P1 and P2, second colmun = validation data).

Description

  • The function performs the following actions:

  • (1) The dataset is split into 2 parts defined by the parameter DEBFIN, P1 and P2.

  • (2) On each sub-period, c_PROPAG is calibrated with the lsqrsolve function.

  • (3) The calibration quality on P1 and P2 is assessed by calculating quality criteria (see CRIT function).

  • (4) The model quality in validation mode is assessed by calculating quality criteria on a simulation made on P1 with parameters from P2 and vice-versa.

Examples

    // Time
    t = (0:500)';

    // Upstream hydrograph (two identical flood hydrographs)
    Qup=[t.*exp(-(t/50)^2);t.*exp(-(t/50)^2)];
    
    // Downstream hydrograph (two identical flood hydrographs)
    Qdo=[t.*exp(-((t+50)/200)^2);t.*exp(-((t+50)/200)^2)];

   // Independant optimisation on the two flood hydrgraphs
   [X,CR,CRlog,CRrac,CALC] = PROPAG_CAL_LM(Qdo,Qup,1,11,'def',1);

   // Plot of results in validation mode
   t2=0:2*size(t,1)-1;CALC(find(CALC<0))=%nan;
   plot(t2,Qup,'k',t2,Qdo);xstring('','Time','Discharge');
   plot(t2,CALC(:,2),'r');legend(['Uptream, Obs','Downstream, Obs','Downstream, Calc'],%f);

  

See Also

c_PROPAG , lsqrsolve , CRIT

Authors

Julien Lerat

CEMAGREF Antony, HBAN Unit, julien.lerat@cemagref.fr

Bibliography

Klemes, V. (1986). "Operational testing of hydrological simulation models." Hydrological Sciences Journal/Journal des Sciences Hydrologiques 31(1): 13-24.