Login  Register

Re: Passing on a discount curve without interpolating

Posted by Peter Caspers-4 on Oct 26, 2015; 6:17pm
URL: http://quantlib.414.s1.nabble.com/Passing-on-a-discount-curve-without-interpolating-tp16956p16966.html

Hi Teejayu,

in the cloned yield term structure class I have two double vectors
with one entry per day each. If you clone a term structure with
maximum date 31-12-2199 (which is the maximum date allowed in ql), the
instance is already consuming over 1 MB of main memory. I grew up with
computers that had 4 KB and later 64 KB of main memory. This is also
why I am not using a linear interpolation object, since this would
create two more vectors (s_ and primitiveConst_) of the same size, so
3 MB already (for one curve with maximum length).

Best regards
Peter


On 26 October 2015 at 17:50, teejayu <[hidden email]> wrote:

> Hi Peter,
>
> Thanks for your reply.
>
> I am indeed feeding in a long vector of days (daily for 30yrs)...but I agree
> that it's prb not going to be saving too much speed there. I will implement
> a similar class (of your example) and see if it's worth it.
>
> At the same time, could you elaborate on what you meant by "memory
> footprint"? What exactly is the concern about memory in using such a cloned
> class?
>
> Thanks,
> TJ
>
>
>
> --
> View this message in context: http://quantlib.10058.n7.nabble.com/Passing-on-a-discount-curve-without-interpolating-tp16956p16964.html
> Sent from the quantlib-users mailing list archive at Nabble.com.
>
> ------------------------------------------------------------------------------
> _______________________________________________
> QuantLib-users mailing list
> [hidden email]
> https://lists.sourceforge.net/lists/listinfo/quantlib-users

------------------------------------------------------------------------------
_______________________________________________
QuantLib-users mailing list
[hidden email]
https://lists.sourceforge.net/lists/listinfo/quantlib-users