completed and tested isTransformationValid