1

I'm building a circuit to monitor AC current for my house and I have run into a need (in software) to multiply the max ADC value for a given sampling by 0.707 to scale the reading to obtain the correct amperage. There is a subsequent scaling multiplier that deals with the ADC bit resolution and the max amp value of the sensor, but I understand that.

I am assuming the 0.707 is cos or sin of pi/4.

Therefore, my question is:

What role in the computation does this trigonometric value play?

  • I'm sure you could make some trigonometric argument that connects it to cos(π/4), but I think it's more useful to think of it as 1/√2 (which also happens to be cos(π/4)). – Hearth Oct 07 '23 at 12:58

2 Answers2

4

I'm building a circuit to monitor AC current for my house and I have run into a need (in software) to multiply the max ADC value for a given sampling by 0.707 to scale the reading to obtain the correct amperage.

The AC current in your house will not look very sinusoidal so any simple "one-size-fits-all" multiplier that converts the peak value to the RMS is going to produce significantly inaccurate results. If you want accuracy, sample at a fairly decent rate (circa 1 kHz for 50 Hz AC mains), square each sample, sum each squared value over an appropriate period (say 1 second) then divide by the number of samples taken in that one second interval. Finally, take the square root to get the true RMS value.

This is what "RMS" means; it's the square root of the mean of the squared values.

Why multiply by cos(pi/4)

Somebody's daft idea of converting values to RMS. It only works for sinewaves and AC current is nearly always strongly non-sinusoidal. This is an example from ReseachGate that shows the typical current taken by a TV: -

enter image description here

Andy aka
  • 456,226
  • 28
  • 367
  • 807
0

Value like voltage or current that is sine wave has a ratio of sqrt(2) between peak and RMS.

For example, if you have 230VAC mains, that's a sine wave with a peak of 325V.

So in the end, cos(pi/4) just also happens to be sqrt(2) so that is the same scale factor just in exotic notation.

Justme
  • 147,557
  • 4
  • 113
  • 291