The present invention provides a method for compressing a
signal, the method comprising: obtaining a main
signal via a
signal recording module; modeling a model signal of the main signal via a processor by: obtaining a sampled signal via the processor; obtaining a windowed signal via the processor; and extracting, via the processor: a
fundamental frequency waveform having a fundamental magnitude and a fundamental phase; and at least one
harmonic frequency waveform having a
harmonic magnitude and a
harmonic phase; wherein the model signal comprises the
fundamental frequency waveform and the at least one harmonic frequency waveform; calculating, via the processor, an
error signal between a reconstructed signal and the main signal; determining, via the processor, an optimal
gain according to at least: an averaging step providing an average, a predefined threshold, and a scaling signal, wherein the scaling signal is a historical
error signal scaled by iteratively: averaging a difference between the
error signal and the scaling signal, wherein the optimal
gain comprises a predefined
gain when the average satisfies the predefined threshold; determining, via the processor, an index from a residual signal by: determining the residual signal; vector quantizing the residual signal; and indexing the vector quantized residual signal; synthesizing, via the processor, a compressed signal, wherein the compressed signal comprises: the fundamental phase; the fundamental magnitude; the
harmonic phase; the harmonic magnitude the optimal gain; the index. Thus, the
compression method preferably overcomes problems associated with current compression techniques, and provides a suitable technique for compressing a signal that can be used to infer a type of load on a circuit.