Pound lines again

Hi,

In Dynare v4, the set of authorized functions inside the model block is limited to standard functions (arithmetic operators, sqrt, log, exp, trigonometry…). This is due to the fact that in Dynare v4 we compute analytical derivatives of the model, while in Dynare v3 we were only computing numerical derivatives. Therefore, we need to know the analytical derivative of any function used in the model block.

In future releases of Dynare, we will introduce the possibility of using arbitrary functions in the model block by allowing the user to provide its first (and possibly second) derivatives.

Also note that there already exist a “max” function, but which only accepts two arguments. In your case you could write:

blah = max(a, max(b, c));

Best

Sébastien