How to use this calculator
Separate coarse and fine-scale energy in a short signal with an orthonormal Haar transform.
- Enter Uniform samples (signal units), Decomposition levels. Match the units shown beside each field and review the result together with the assumptions below.
- Read the worked example below to check the expected input format and result.
- Compare another scenario by changing one input at a time. Use Reset to return to the starting values.
Multilevel Haar energy decomposition explained
The Haar transform splits adjacent samples into normalized averages and differences, then repeats the average transform at each requested level. For a complete dyadic series, squared signal energy is preserved as approximation energy plus detail energies.
Inputs, symbols, and units
x— Uniform samples (signal units)- Chronological real samples; use a comma-separated list in the same signal units. Use comma-separated values in the stated order.
levels— Decomposition levels- Number of orthonormal pair-average/difference stages. Enter a whole number.
Formula and method
a=(x₂ₖ+x₂ₖ₊₁)/√2 and d=(x₂ₖ−x₂ₖ₊₁)/√2 at each level; total squared norm=final approximation energy+all detail energies.
No boundary extension is used; the length must divide evenly at every selected stage. Energy refers to a squared sample norm rather than time-integrated physical energy.
A worked scenario
Uniform samples (signal units) = [3, 1, 0, 2, 4, 0, 1, 1]; Decomposition levels = 2.
- Final approximation energy: 18 signal units²
- All discarded detail energy: 14 signal units²
- Remaining coefficients: 2 coefficients
The eight-sample default block is reduced through two pairwise stages, leaving two coarse coefficients.
Assumptions and edge cases
At most 256 samples and no thresholding, denoising or reconstructed waveform.
Reading the outputs
Approximation and detail energy should sum to the original sum of squared samples; coefficient count confirms the reduction.
Frequently asked questions
Why use square root two?
It preserves energy under each pair transform.
Can the length be odd?
Not for a selected level that requires an unmatched pair.
Is detail energy always noise?
No; it can contain real edges and fast signal changes.
How do I use the Multilevel Haar energy decomposition calculator?
Enter Uniform samples (signal units), Decomposition levels. Match the units shown beside each field and review the result together with the assumptions below.
What is a worked example of Multilevel Haar energy decomposition?
Uniform samples (signal units) = [3, 1, 0, 2, 4, 0, 1, 1]; Decomposition levels = 2. Final approximation energy: 18 signal units² All discarded detail energy: 14 signal units² Remaining coefficients: 2 coefficients The eight-sample default block is reduced through two pairwise stages, leaving two coarse coefficients.
Read our calculation methodology.