private static RandomVariable getWorstPerformance(HybridAssetLIBORModelMonteCarloSimulation model, double exerciseDate, double[] baseLevels) throws CalculationException {
		RandomVariable worstPerformance = null;
		for(int assetIndex=0; assetIndex<baseLevels.length; assetIndex++) {
			RandomVariable underlying = model.getAssetValue(exerciseDate, assetIndex);
			RandomVariable performance = underlying.div(baseLevels[assetIndex]);
			worstPerformance = worstPerformance != null ? worstPerformance.cap(performance) : performance;
		}

		return worstPerformance;
	}
private static RandomVariable getWorstPerformance ( HybridAssetLIBORModelMonteCarloSimulation model , double exerciseDate , double [ ] baseLevels ) throws CalculationException { RandomVariable worstPerformance = null ; for ( int assetIndex = 0 ; assetIndex < baseLevels . length ; assetIndex ++ ) { RandomVariable underlying = model . getAssetValue ( exerciseDate , assetIndex ) ; RandomVariable performance = underlying . div ( baseLevels [ assetIndex ] ) ; worstPerformance = worstPerformance != null ? worstPerformance . cap ( performance ) : performance ; } return worstPerformance ; }
@param model
@param exerciseDate
@param baseLevels
@return
@throws CalculationException