Compute RMS value of non-stationary signal I would like to know what is the most accurate way to compute a measured signal's fundamental RMS value as a function of time.

The following is true for the considered signal:


signal represents a voltage
sample rate: fs = 6 kHz
capture time: t = 100 s
fundamental frequency: f1 = 60 Hz
signal is not a pure sinusoidal but has additional frequency content
amplitude of the signals fundamental changes slowly over time
The general way to obtain high resolution envelope of a signal is called envelogram which is the magnitude of the analytic signal obtained from your original signal(the analytic signal obtained by using Hilbert transform).

Simply take FFT of whole signal to obtain the spectrum, then replace the value of spectrum over negative frequencies with zero (keep the value of spectrum over positive frequencies as before). Now taking inverse FFT will give you a complex signal which its magnitude is the envelope of your signal which is the instantaneous power or RMS.
By applying a band pass filter around your fundamental frequency you could obtain the RMS of your fundamental frequency.

Another way is to use time-frequency analysis which is similiar to the method you suggested (it uses a moving window instead of splitting signal)