Store the deformation data of a complex C in a file with name fn.
The object saveDeformations is a method function.