I don't think there's a simple formula since the measurement methods differ.
Btw RMS is not a measurement specification it's just peak power / 1.4142. So a RMS specification could be measured at any conditions (distortion, frequency, etc.), but I think that the distortion is almost always specified.
DIN on the other hand specify several conditions (warm up time, max THD (I think it's 0.7% for pre or power amps and 1% for integrated amps), frequency(1kHz), time (not sure about how long)), DIN power is a RMS value.
I'm not sure about EIAJ specifications, I think it's similar to DIN but more strict.
I had an all-in-one stereo once that was specified to 16W DIN and 25W RMS (10% THD)
As far as i know , DIN power output is measured after a 1h
warm up phase at 100%.
The test frequency is 1kHz at a THD of <=1% for 8 min,the lowest readout during this time is the DIN rating.
Usally 100 W DIN is about 80 to 90 W RMS.