### Question:
Tanh extends TransferFunction implements Serializable { @Override final public double getOutput(double input) { if (Math.abs(input) * slope > 100) { return Math.signum(input) * 1.0d; } double E_x = Math.exp(2.0d * slope * input); output = amplitude * ((E_x - 1.0d) / (E_x + 1.0d)); return output; } Tanh();  Tanh(double slope);  Tanh(Properties properties); @Override final double getOutput(double input); @Override final double getDerivative(double input); double getSlope(); void setSlope(double slope); double getAmplitude(); void setAmplitude(double amplitude);  }### Answer:
@Test public void testGetOutput() { double result = instance.getOutput(input); assertEquals(expected, result, FloatingAccuracy.ACCURACY); }