80d40fd319
git-svn-id: https://bucket.mit.edu/svn/nilm/zoom@7998 ddd99763-3ecb-0310-9145-efcb8ce7c51f
27 lines
698 B
Plaintext
27 lines
698 B
Plaintext
Some processing thoughts:
|
|
|
|
grep ^1 log | tail -n +119 > log-locked
|
|
|
|
octave:
|
|
|
|
octave:1> a=load("log-locked");
|
|
octave:3> t=1:10000;
|
|
octave:5> keith=a(:,3);
|
|
octave:7> calib=a(1,4)
|
|
calib = 1.9507
|
|
octave:8> dac=a(:,5);
|
|
octave:9> adc=a(:,6);
|
|
octave:12> meas=-(dac - calib * adc);
|
|
octave:25> plot(keith(t),meas(t))
|
|
octave:48> [p, errorest] = polyfit(keith, meas, 1);
|
|
octave:57> p
|
|
p =
|
|
|
|
20405.9116453934 -31177.1688297700
|
|
|
|
octave:59> plot(t,keith(t) * p(1) + p(2),t,meas(t))
|
|
octave:66> t=1:710872;
|
|
octave:73> plot(t,keith(t) * p(1) + p(2) - meas(t))
|
|
octave:75> axis([0 710872 10 -10])
|
|
octave:76> # generally +- 5 over the entire range. this is on the scale of "dac values" so that's pretty damn good.
|