Exemplo n.º 1
0
 def getDerivative(self, m):
     """
     returns the value for the derivative of the mapping for m
     """
     return ((self.s_max - self.s_min) / 2.0) * (1.0 - tanh(m) ** 2.0)
Exemplo n.º 2
0
 def getDerivative(self, m):
     """
     returns the value for the derivative of the mapping for m
     """
     return ((self.s_max - self.s_min) / 2.) * (1. - tanh(m)**2.)
Exemplo n.º 3
0
 def getValue(self, m):
     """
     returns the value of the mapping for m
     """
     return (self.s_max + self.s_min) / 2.0 + (self.s_max - self.s_min) / 2.0 * tanh(m)
Exemplo n.º 4
0
 def getValue(self, m):
     """
     returns the value of the mapping for m
     """
     return (self.s_max + self.s_min) / 2. + (self.s_max -
                                              self.s_min) / 2. * tanh(m)