Considering a D0->π+K- where the D meson decays from rest.
If one was to want to calculate the invariant mass of the D meson by measuring the momenta of the pion and kaon, following from conservation of momentum:
m2=(Eπ+EK)2-(pπ+pK)2
However by inputting numerical data
Eπ=137MeV
EK=493MeV...