public void checkInterval ( final float x1 , final float x2 ) throws InvalidIntervalException { final float y1 = m_aFunction . at ( x1 ) ; final float y2 = m_aFunction . at ( x2 ) ; // The interval is invalid if y1 and y2 have the same signs. if ( y1 * y2 > 0 ) throw new InvalidIntervalException ( ) ; }
Check the interval .