The piece played by the grandmother (and later by Deborah Kerr's character) in An Affair to Remember (1957) is "Lara's Theme" (also known as "Somewhere, My Love").
Composed by Maurice Jarre for the 1965 film Doctor Zhivago—wait, correction: An Affair to Remember uses Hugo Friedhofer's score. The specific piano piece is "Our Love Affair" (Main Theme) by Friedhofer. "Lara's Theme" is from Doctor Zhivago (also 1965, Jarre). The two are often conflated due to similar lush, romantic orchestral style.
In the 1957 film: The grandmother plays the main romantic theme by Hugo Friedhofer.