#78: Problem with derivatives of power function at point zero
--------------------------+-------------------------------------------------
Reporter: sebastien | Owner: sebastien
Type: bug | Status: new
Priority: major | Milestone:
Component: Preprocessor | Version: 4.1.0
Keywords: |
--------------------------+-------------------------------------------------
There is currently a problem with the derivatives of the power function
f(x)=x^p^ at the point x=0.
The power function f(x)=x^p^ well defined for x>0 and for any p, since
f(x)=e^p*ln(x)^.
The domain of definition of this function can be extended to x=0 with the
following rules when p>0:
* f(0)=0
* f is differentiable k times at x=0, where k is the integer part of p,
and f'^k^=0
And when p is an strictly positive integer, the function is differentiable
at any order, and its derivative at zero is zero.
When p is a constant, the preprocessor computes the right value of the
derivatives at x=0, using simplifications rules.
But when p is a parameter, the preprocessor will not give the right value
for integer values of p.
Currently the derivation rule is applied by the preprocessor, the k-th
derivative of f(x) is equal to:
p*(p-1)*...*(p-k+1)*x^p-k^
So when p is an integer, the (p+1)-th derivative computed at x=0 will give
a NaN (0 times infinity), while it ought to be zero.
This problem typically arises in models with adjustment costs where the
curvature (the exponent) of the cost is a integer parameter, and the cost
is zero at steady state.
The solution is probably to create, in the preprocessor, a new operator
called "derivative of power function at order k". This operator would
output a code like that in the M-file:
{{{
dxp=deriv(x,p,k) % The k-th derivative of x^p
if (p > 0) && (abs(p - round(p)) < 1e-12 && k >= p
dxp = 0;
else
dxp = x^(p-k);
for i=1:k-1
dxp = dxp*p;
p = p-1;
end
end
}}}
--
Ticket URL: <https://www.dynare.org/trac/ticket/78>
Dynare <http://www.dynare.org>
The Dynare project
#156: distclean doesn't work if Dynare was built with --disable-octave
--------------------------+-------------------------------------------------
Reporter: michel | Owner: sebastien
Type: bug | Status: new
Priority: minor | Milestone:
Component: Preprocessor | Version:
Keywords: |
--------------------------+-------------------------------------------------
This seems to be a problem with the options of the build system.
--
Ticket URL: <https://www.dynare.org/trac/ticket/156>
Dynare <http://www.dynare.org>
The Dynare project
Hi George,
I plan to (for dynare>=4.3) entirely rewrite the kalman filter routines (matlab codes) to allow for unexpected structural breaks. I use Slicot because this
library provides a lot of utilities for handling state space models and evaluating kalman filters. For instance, I use a solver for the discrete
Riccatti equations, and use the solution for initializing the kalman filter. This gives a much more stable evaluation of the likelihood (also the
evaluation is much faster). This evaluation is biased but its variance is smaller. As a first approximation (for large models) I use this trick when
looking for the posterior mode (or maximum likelihood). This gives a very good initial guess when estimating the posterior mode. I will also use the
library to reduce the size of the state space model and for comparison purposes.
Best,
Stéphane.
George Perendia <george(a)perendia.orangehome.co.uk> writes:
> Hi Stephane
> From the email below I gather you are planning to use SLICOT for some work with KF.
> I was just intrigued and wandered if you can shed me some light on that or send me some existing paper-work if poss and you have a moment for that.
>
> Best regards
> George
>
> -------- Original Message --------
> Subject: Re: SLICOT Library
> Date: Mon, 13 Dec 2010 10:24:07 +0100
> From: Sébastien Villemot <sebastien.villemot(a)ens.fr>
> To: George Perendia <george(a)perendia.orangehome.co.uk>
>
> George Perendia <george(a)perendia.orangehome.co.uk> writes:
>
>> I noticed a new sub-directory of Dynare mex files - SLICOT Library.
>> What is going to be the main use of the control system SLICOT Library within
>> Dynare that is in mex slicot directory and how will it be accessed? Are there
>> any wiki pages on it?
>
> SLICOT is a multi-purpose optimal control library written in Fortran,
> see http://www.slicot.org/
>
> Stéphane is now using it in some extensions of the Kalman filter. If you
> want more details on that, please ask him directly.
>
> We included it in Dynare distribution (instead of simply making Dynare
> depend on it), because there is no pre-packaged version of this library
> (neither in Debian/Ubuntu nor in Cygwin).
>
> Best,
--
Stéphane Adjemian
Université du Maine, GAINS & CEPREMAP
http://www.dynare.org/stepan
#154: Change build process to make libslicot optional on Mac OS X
--------------------------------------+-------------------------------------
Reporter: houtanb | Owner: sebastien
Type: bug | Status: new
Priority: minor | Milestone: 4.2
Component: Build system / Packaging | Version:
Keywords: |
--------------------------------------+-------------------------------------
XCode doesn't provide a Fortran compiler so Mac users will either have to
find one precompiled or compile it on their own. Hence, libslicot should
be optional in the build process.
--
Ticket URL: <https://www.dynare.org/trac/ticket/154>
Dynare <http://www.dynare.org>
The Dynare project
#155: GraphvizDigraph has been removed from recent Boost versions
--------------------------+-------------------------------------------------
Reporter: michel | Owner: ferhat
Type: bug | Status: new
Priority: critical | Milestone:
Component: Preprocessor | Version:
Keywords: |
--------------------------+-------------------------------------------------
It appears that
GraphvizDigraph was removed from Boost in version 1.43. See
https://svn.boost.org/trac/boost/ticket/4762
GrahphvizDigraph is used in MinimumFeedbackSet.hh (line 58) and in
ModelTree.cc (line 513)
Boost version 1.45 is available in Redhat version 6, but only version 1.42
is available in Debian testing/unstable
--
Ticket URL: <https://www.dynare.org/trac/ticket/155>
Dynare <http://www.dynare.org>
The Dynare project
Dear Paul,
thank you very much for reporting the problem. It appears that
GraphvizDigraph was removed from Boost in version 1.43. See
https://svn.boost.org/trac/boost/ticket/4762
As Debian is still at version 1.42, we weren't aware from the problem.
We are going to fix this. In the meantime, you should try to get version
1.42 of the Boost graphic library.
Best,
Michel
PS. The Dynare forum is a better way to contact us, rather than the
email of the webmaster.
m
On 12/10/2010 04:49 PM, michaud(a)umich.edu wrote:
> You are receiving this mail because Paul Michaud
> michaud(a)umich.edu
> is sending feedback about the site administered by you at http://www.dynare.org.
> The message sent was:
>
> Hi, I'm attempting to build Dynare 4.1.3 from source in a Red Hat Enterprise Linux ES release 4 (Nahant Update 8) environment. To configure I use the following command: ./configure --prefix=/software/dynare/v4.1.3 --with-boost=/software/Boost/v1.45.0 --with-matlab=/software/matlab_2009b MATLAB_VERSION=R2009b According to the configure logs a "make" should build the Dynare preprocessor. Said "make" builds the libmicro.a library just fine. However, in the preprocessor build step it chokes building dynare_m-ModelTree.o. It's complaint is that (starting on line 58) in the MinimumFeedbackSet.hh include file (used by ModelTree.cc) GraphvizDigraph is not declared. The same issue comes up on line 513 of ModelTree.cc. There are some other bits as well but this appears to be the main catalyst. I can forward you the make output but didn't want to clutter up this initial email with all that goo. :-) Thanks much for any help that you can provide! :-) Paul ============================================================================ Paul Michaud Research Computing Stephen M. Ross School of Business at the University of Michigan Email: michaud(a)umich.edu Phone: 734-763-5677 Fax: 734-936-6029 ============================================================================
>
>
>
#73: The macroprocessor fails when the file ends with @#endif or @#endfor
without a new line at the EOF
--------------------------+-------------------------------------------------
Reporter: sebastien | Owner: sebastien
Type: bug | Status: new
Priority: minor | Milestone:
Component: Preprocessor | Version: 4.1.0
Keywords: |
--------------------------+-------------------------------------------------
--
Ticket URL: <https://www.dynare.org/trac/ticket/73>
Dynare <http://www.dynare.org>
The Dynare project