Edson Brusque wrote: > > As to RMS vs averaging, that's what the original question was about. = I > just > > didn't know if doing an RMS calculation had any benifits over just > averaging the > > input signal (better noise immunity, more accurate, more linear, etc.= ...). >=20 > RMS would give you a *more number. >=20 > Let's say you have a dimming application, where your circuit is > connected to mains power @ 220V and you're firing the triac at 90=BA. Y= ou're > measuring the voltage going to the load. If you average your measuring,= it > will say 110V. RMS will say about 155V. Now, if you rectify and "regula= te" > the energy going to the load (with full-cycle rectifying, 4 diodes and = a > capacitor) and measure it with a voltmeter, it will give you a value ve= ry > close to that 155V. This is wrong, with 90' switching there is exactly half the voltage average and half the rms voltage. (and how do you make that "degrees" symbol??) :o) So now i'm confused! Isn't RMS just calculating the AC average?? I was taught that the only point to squaring this and then doing a square root is that this is only math way of making negative values positive for averaging. As programmers we have more power than mathematicians, we are not limited to: 1. square it 2. average it 3. unsquare it We can just do the following: 1. convert - values to + 2. average it Or have I missed something?? Does anyone think we MUST do square and square-root calcs in our PICs and why?? -Roman -- http://www.piclist.com hint: PICList Posts must start with ONE topic: [PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads