• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

wegamekinglc / Derivatives-Algorithms-Lib / 35564769936

21 Sep 2026 05:30AM UTC coverage: 91.674% (-0.001%) from 91.675%
35564769936

push

github

web-flow
refactor: single-source script settings validation in dal-cpp (#407)

* Restrict LSMC regression and exercise decisions to ITM paths

Classic Longstaff-Schwartz regresses the continuation value on the
in-the-money paths (h > 0) only. Including every condition-true path let
deep-OTM (h == 0) paths into the fit, and a regression that undershot
below zero then "exercised" worthless options: on a two-date 90 put the
unfiltered driver exercised 41% of all paths at the mid date against a
25% ITM fraction and underpriced by more than 1% versus the PDE oracle.

FillIncluded now intersects the condition row with h > 0, PathPayoff
requires a strictly positive exercise value, and the fuzzy replay blends
the decision degree with the one-sided CSpr(h, 0, eps) ramp so the blend
converges to the corrected hard rule (degree 0 on the h == 0 atom; a
centered ramp would leave 0.5 there). The empty regression set also
carries the sigma floor now: a count-0 day previously kept sigma_ == 0
and produced NaN continuations in the fuzzy replay's z-normalization.

num_cond_true_paths in the simulation diagnostic accordingly reports the
ITM condition-true count; the dal-public and dal-excel pins move to the
measured values and the dal-python assertion to the semantic bound.

* Anchor the Bermudan PDE s=0 boundary at the next exercise date

During the rollback over (t_e, t_{e+1}] the boundary was
K*exp(-r*(t_e - t)) >= K, anchored one exercise period back; the
Bermudan value at s = 0 is K*exp(-r*(t_{e+1} - t)), anchored at the
segment's right endpoint, exactly as the final segment already did. The
loop now passes the current tNext (read before rollTo reassigns it).

Measured delta on every suite benchmark is exactly zero: the boundary
layer is a few grid cells deep inside the payoff-floored region, and the
projection at each exercise date overwrites precisely that layer, so the
mis-anchoring never reached an interpolated value; the final segment,
the only one whose boundary survi... (continued)

42 of 44 new or added lines in 3 files covered. (95.45%)

15349 of 16743 relevant lines covered (91.67%)

3251504.44 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

87.18
/dal-cpp/dal/script/settings.cpp


Source Not Available

STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc