An implantable ophthalmic device with one or more optical elements coupled to one or more shape-memory members provides dynamically variable optical power to restore lost accommodation in individuals suffering from presbyopia or aphakia. Running current from a power supply through the shape-memory members causes the shape-memory members to heat up. Once the current heats the shape-memory members past a forward phase-transition temperature, the shape-memory members change shape, which, in turn, causes the optical element(s) to move, yielding a corresponding change in effective optical power. Cooling the shape-memory members (e.g., by reducing or stopping the flow of current) below a reverse phase-transition temperature causes the shape-memory members to return to their original shape, which, in turn, restoring the optical element(s) to their original positions and returning the effective optical power to its original level.