Ejemplo n.º 1
0
  def setUp(self):
    self.METER = [1] + [0]*7
    Quantity.yesIKnowTheDangersAndPromiseToBeCareful()

    self.x = np.arange(100)
    self.y = np.sqrt(np.arange(100))
    self.z = np.array( (4, 5, 6, 7) ) * math.e

    self.sx = np.zeros(100) + math.pi
    self.sy = np.cos(self.y)**2
    self.sz = np.array( (4, 5, 6, 7) ) / 13

    self.sym = ['s1', 's2', 's3', 's4']
    self.lab = ['Height', 'Width', 'Depth', 'Thickness']
    self.lat =  ['s_1', 's_2', 's_3', 's_4']

    ms  = data.enumstr('s', 100)
Ejemplo n.º 2
0
 def test_enumstr(self):
   self.assertEqual(data.enumstr('s_', 3), ['s_0', 's_1', 's_2']  )
   self.assertEqual(data.enumstr('s_', 4, 9, 2), ['s_4', 's_6', 's_8']  )