Moved coordinate rotation operations from visualize.py to coordinates.py