def test_applyAngList04(self):
        """applyAngList     -- one-at-time equals all-at-once"""
        ko1 = Kinematics(self.known_points, self.torTree, tolist=0)
        ko2 = Kinematics(self.known_points, self.torTree, tolist=0)        
        result1 = ko1.applyAngList([90.,-90.,0.], self.idmtx)[:,:3]

        # do the rotations separately
        ko2.applyAngList([90.,0.,0.])
        result2 = ko2.applyAngList([0.,-90.,0.], self.idmtx)[:,:3]
        self.assertArrayEqual(result1, result2)
Beispiel #2
0
    def test_applyAngList04(self):
        """applyAngList     -- one-at-time equals all-at-once"""
        ko1 = Kinematics(self.known_points, self.torTree, tolist=0)
        ko2 = Kinematics(self.known_points, self.torTree, tolist=0)
        result1 = ko1.applyAngList([90., -90., 0.], self.idmtx)[:, :3]

        # do the rotations separately
        ko2.applyAngList([90., 0., 0.])
        result2 = ko2.applyAngList([0., -90., 0.], self.idmtx)[:, :3]
        self.assertArrayEqual(result1, result2)
Beispiel #3
0
    def test_applyAngList022(self):
        """applyAngList     -- return correct coords ( 0,-90, 0)"""
        ko = Kinematics(self.known_points, self.torTree, tolist=0)
        result = ko.applyAngList([0., -90., 0.], self.idmtx)[:, :3]

        self.known_points[0] = [1., 1., 1.]
        self.known_points[2] = [1., 0., 0.]
        self.assertArrayEqual(self.known_points, result)
    def test_applyAngList022(self):
        """applyAngList     -- return correct coords ( 0,-90, 0)"""
        ko = Kinematics(self.known_points, self.torTree, tolist=0)
        result = ko.applyAngList([0.,-90.,0.], self.idmtx)[:,:3]

        self.known_points[0] = [1., 1., 1.]
        self.known_points[2] = [1., 0., 0.]
        self.assertArrayEqual(self.known_points, result)
    def test_applyAngList021(self):
        """applyAngList     -- return correct coords (90, 0, 0)"""
        ko = Kinematics(self.known_points, self.torTree, tolist=0)
        result = ko.applyAngList([90.0, 0.0, 0.0], self.idmtx)[:, :3]

        self.known_points[0] = [0.0, 1.0, 2.0]
        self.known_points[1] = [0.0, 1.0, 1.0]
        self.known_points[2] = [-1.0, 1.0, 1.0]
        self.assertArrayEqual(self.known_points, result)
Beispiel #6
0
 def test_applyAngList01(self):
     """applyAngList     -- return correct coords (360., 360., 360.)"""
     ko = Kinematics(self.known_points, self.torTree, tolist=0)
     result = ko.applyAngList([360., 360., 360.], self.idmtx)[:, :3]
     self.assertArrayEqual(self.known_points, result)
Beispiel #7
0
 def test_applyAngList00(self):
     """applyAngList     -- return correct coords (0., 0., 0.)"""
     ko = Kinematics(self.known_points, self.torTree, tolist=1)
     self.assertEqual(self.known_points,
                      ko.applyAngList([0, 0, 0], self.idmtx))
 def test_applyAngList01(self):
     """applyAngList     -- return correct coords (360., 360., 360.)"""
     ko = Kinematics(self.known_points, self.torTree, tolist=0)
     result = ko.applyAngList([360.,360.,360.], self.idmtx)[:,:3]
     self.assertArrayEqual(self.known_points, result)
 def test_applyAngList00(self):
     """applyAngList     -- return correct coords (0., 0., 0.)"""
     ko = Kinematics(self.known_points, self.torTree, tolist=1)
     self.assertEqual(self.known_points, ko.applyAngList([0,0,0], self.idmtx))