before flipping axes in FD code