Esempio n. 1
0
    def testTransformation(self):

        atoms = UBI.ca
        coords = UBI.getCoords()
        matrix = eye(4)
        moveAtoms(atoms, by=matrix, ag=True)
        assert_equal(UBI._getCoords(), coords)
Esempio n. 2
0
    def testByArgument(self):

        atoms = UBI
        offset = ones(3) * 10.
        coords = atoms.getCoords()
        moveAtoms(atoms, by=offset)
        assert_equal(atoms._getCoords(), coords + offset)
Esempio n. 3
0
    def testTransformation(self):

        atoms = UBI.ca
        coords = UBI.getCoords()
        matrix = eye(4)
        moveAtoms(atoms, by=matrix, ag=True)
        assert_equal(UBI._getCoords(), coords)
Esempio n. 4
0
    def testByArgument(self):

        atoms = UBI
        offset = ones(3) * 10.
        coords = atoms.getCoords()
        moveAtoms(atoms, by=offset)
        assert_equal(atoms._getCoords(), coords + offset)
Esempio n. 5
0
    def testToArgument(self):

        atoms = UBI.ca

        coords = UBI.getCoords()
        center = atoms._getCoords().mean(0)
        moveAtoms(atoms, to=zeros(3), ag=True)
        assert_equal(UBI._getCoords(), coords - center)
Esempio n. 6
0
    def testToArgument(self):

        atoms = UBI.ca

        coords = UBI.getCoords()
        center = atoms._getCoords().mean(0)
        moveAtoms(atoms, to=zeros(3), ag=True)
        assert_equal(UBI._getCoords(), coords - center)