Molecular memory

Molecular memory was a science that was developed on Earth many years ago where metal alloys were crafted that were designed to return to a specific shape if heat was applied.

A more advanced form of this technology was referred to as Molecular engineering and was related to Nanotechnology. (TNG novel: The Romulan Prize)