Necessary and sufficient conditions for constructing orthonormal wavelet bases | Synapse