/src/main/java/net/finmath/fouriermethod/calibration/models/CalibratableHestonModel.java
final double kappa = kappaInfo.getIsParameterToCalibrate( ) == true ? kappaInfo.getConstraint( ).apply( parameters[2]) : descriptor.getKappa( ) ; double theta = thetaInfo.getIsParameterToCalibrate( ) == true ? thetaInfo.getConstraint( ).apply( parameters[1]) : descriptor.getTheta( ) ;final double volatility = volatilityInfo.getIsParameterToCalibrate( ) == true ? volatilityInfo.getConstraint( ).apply( parameters[0]) : descriptor.getVolatility( ) ;
final double volatility = volatilityInfo.getIsParameterToCalibrate ( ) == true ? volatilityInfo.getConstraint ( ) .apply ( parameters[0] ) : descriptor.getVolatility ( ) ; double theta = thetaInfo.getIsParameterToCalibrate ( ) == true ? thetaInfo.getConstraint ( ) .apply ( parameters[1] ) : descriptor.getTheta ( ) ; final double kappa = kappaInfo.getIsParameterToCalibrate ( ) == true ? kappaInfo.getConstraint ( ) .apply ( parameters[2] ) : descriptor.getKappa ( ) ;
this.applyFellerConstraint = applyFellerConstraint; parameterUpperBounds = extractUpperBounds(); parameterLowerBounds = extractLowerBounds(); } @Override public CalibratableHestonModel getCloneForModifiedParameters(final double[] parameters) { <extra_id_0> final double xi = xiInfo.getIsParameterToCalibrate() == true ? xiInfo.getConstraint().apply(parameters[3]) : descriptor.getXi(); final double rho = rhoInfo.getIsParameterToCalibrate() == true ? rhoInfo.getConstraint().apply(parameters[4]) : descriptor.getRho(); if(applyFellerConstraint && 2*kappa*theta < xi*xi) { theta = xi*xi / (2 * kappa) + 1E-9; } final HestonModelDescriptor newDescriptor = new HestonModelDescriptor(descriptor.getReferenceDate(),