Skip to content

Print unit cell in the xyz header #38

@briling

Description

@briling

v can translate a unit cell and we can make use of that in xyzrender. Normal rotation of a molecule is fine because we only need the positions. If there is a unit cell involved too, then we need to rotate that alongside the atoms. The rotation alone is fine because we can work out the rotation applied in v based on the positions. However, when we move the unit cell then we can't just get a rotation matrix to equivalently reorient the unit cell too.

So we can use vmol.capture(args=["exitcom:uz"])

Then with a cell, we return the translated + rotated coordinates, and also the rotation applied.
Alternatively, one could also simply return the reoriented cell alongside the xyz coordinates which may be more in keeping with printing the coordinates?
Or the cell could be printed in the header line of the xyz like the extxyz style.

Does that make any sense?

Originally posted by @aligfellow in #37 (comment)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions