Re: [QuantLib-svn] SF.net SVN: quantlib:[17075] trunk/QuantLib

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Re: [QuantLib-svn] SF.net SVN: quantlib:[17075] trunk/QuantLib

Luigi Ballabio
On Tue, 2010-02-09 at 09:40 +0000, [hidden email] wrote:
> Log Message:
> -----------
> added MixedInterpolation

Question:

> +            Real primitive(Real x) const {
> +                if (x<*(this->xBegin2_))
> +                    return interpolation1_.primitive(x, true);
> +                return interpolation2_.primitive(x, true);
> +            }

shouldn't the second one be:

    return interpolation1_.primitive(*xBegin2_, true) +
           interpolation2_.primitive(x, true);

to account for the first piece of the integral?

Luigi


--

I am extraordinarily patient, provided I get my own way in the end.
-- Margaret Thatcher



------------------------------------------------------------------------------
The Planet: dedicated and managed hosting, cloud storage, colocation
Stay online with enterprise data centers and the best network in the business
Choose flexible plans and management services without long-term contracts
Personal 24x7 support from experience hosting pros just a phone call away.
http://p.sf.net/sfu/theplanet-com
_______________________________________________
QuantLib-dev mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-dev