Changeset 229
- Timestamp:
- 08/07/08 05:49:52 (4 months ago)
- Files:
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/QLNet/QLNet/Termstructures/Iterativebootstrap.cs
r228 r229 80 80 ts_.data_ = new InitializedList<double>(n + 1); 81 81 ts_.data_[0] = ts_.initialValue(ts_); 82 for (i=0; i<n; ++i) 83 ts_.data_[i+1] = ts_.initialGuess(); 82 84 } 83 85 … … 116 118 ts_.interpolation_ = ts_.interpolator_.interpolate(ts_.times_, i + 1, ts_.data_); 117 119 } catch { 118 // if the target interpolation is not usable yet 120 if (!ts_.interpolator_.global) 121 throw; // no chance to fix it in a later iteration 122 123 // otherwise, if the target interpolation is not usable yet 119 124 ts_.interpolation_ = new Linear().interpolate(ts_.times_, i + 1, ts_.data_); 120 125 }