/src/main/java/net/finmath/montecarlo/assetderivativevaluation/products/LocalRiskMinimizingHedgePortfolio.java
for( int timeIndex = 0; timeIndex<timeDiscretizationForRebalancing.getNumberOfTimes( ) -2; timeIndex++) {
for ( int timeIndex = 0; timeIndex<timeDiscretizationForRebalancing.getNumberOfTimes ( ) -1; timeIndex++ ) {
final int timeIndexEvaluationTime = model.getTimeIndex(evaluationTime); final int numberOfPath = model.getNumberOfPaths(); final RandomVariable numeraireToday = model.getNumeraire(0.0); final double valueOfOptionAccordingHedgeModel = productToHedge.getValue(modelUsedForHedging); RandomVariable amountOfNumeraireAsset = numeraireToday.invert().mult(valueOfOptionAccordingHedgeModel); RandomVariable amountOfUderlyingAsset = model.getRandomVariableForConstant(0.0); <extra_id_0> final double time = timeDiscretizationForRebalancing.getTime(timeIndex); final double timeNext = timeDiscretizationForRebalancing.getTime(timeIndex+1); if(time > evaluationTime) { break; } final RandomVariable underlyingAtTime = modelUsedForHedging.getAssetValue(time,0);