/src/main/java/net/finmath/marketdata/model/volatilities/CapletVolatilities.java
int maturityGreaterEqualIndex = Arrays.binarySearch ( maturities, maturity ) ;
synchronized (lazyInitLock) { if(maturities == null) { maturities = capletVolatilities.keySet().toArray(new Double[0]); } Arrays.sort(maturities); } <extra_id_0> if(maturityGreaterEqualIndex < 0) { maturityGreaterEqualIndex = -maturityGreaterEqualIndex-1; } if(maturityGreaterEqualIndex > maturities.length-1) { maturityGreaterEqualIndex = maturities.length-1; }