... | ... | @@ -3,7 +3,8 @@ see [code](https://github.com/Ibasam/IBASAM/blob/master/IBASAM/R/river_climate_m |
|
|
|
|
|
The climate in the simulated river was described by daily water temperature and flow. As explained in the input section, the time series of temperature and flow of a real river can be used for parameterization purpose or specific simulations. However, for further simulations and to obtain realistic replicates of time series of these two environmental factors, a random autore- gressive sinusoidal function was used for each of these factors. The mathematical form of these two functions was:
|
|
|
|
|
|
> sinus_model_resid_ar <-
|
|
|
```
|
|
|
sinus_model_resid_ar <-
|
|
|
function (m, a, cs, alp, bet, d, nbd)
|
|
|
{
|
|
|
error <- numeric(length(d))
|
... | ... | @@ -15,7 +16,7 @@ function (m, a, cs, alp, bet, d, nbd) |
|
|
}
|
|
|
return(tm)
|
|
|
}
|
|
|
|
|
|
```
|
|
|
where Mean and Amp were the mean and amplitude of the envi- ronmental parameter (temperature or flow) over a year, t was the Julian day, cs was a shifting parameter to adjust the sinusoidal signal and AR(t) was an autoregressive random error of the form:
|
|
|
|
|
|
|
... | ... | |