Measuring neutron star mass and radius with three mass–radius relations