Class TopHatFunction
- java.lang.Object
-
- com.opengamma.strata.math.impl.function.special.TopHatFunction
-
public class TopHatFunction extends Object implements Function<Double,Double>
Class representing the top-hat function, defined as: $$ \begin{align*} T(x)= \begin{cases} 0 & x < x_1\\ y & x_1 < x < x_2\\ 0 & x > x_2 \end{cases} \end{align*} $$ where $x_1$ is the lower edge of the "hat", $x_2$ is the upper edge and $y$ is the height of the function. This function is discontinuous at $x_1$ and $x_2$.
-
-
Constructor Summary
Constructors Constructor Description TopHatFunction(double x1, double x2, double y)
Creates an instance.
-