add: boolean, trapezoidal and sinusoidal functions, and related unit test