refactoring for transformation matrix