%pylab inline import pywt import numpy as np import pylab as pl import pyrem as pr

In [53]:
signal = np.sin(np.linspace(0,10 * pi, 1000))

signal2 = np.sin(np.linspace(10,110 * pi, 1000))


signal3 = np.sin(np.linspace(0, 1000* pi, 1000))

#signal= signal2
#signal2 = signal
sig = pr.Signal(signal + signal2 + signal3, 200)
sig


Out[53]:

In [54]:
coefs = pywt.wavedec(sig, 'db1')

In [55]:
for c in coefs:
    pl.figure()
    print len(c), sum(c **2) 
    pl.plot(c)


2 18.4137349062
2 0.383832587669
4 130.840897579
8 235.385864659
16 103.530107683
32 32.5103925134
63 256.702221553
125 169.363962555
250 53.2984581317
500 513.798548402

In [ ]: