??? 12/09/04 02:09 Read: times |
#82795 - Calculating RMS Responding to: ???'s previous message |
If you cut 50% of the sine wave you still need to include the samples where the value is 0 in the calculation - you're trying to compute energy over time, if you ignore some of the time, your result will be incorrect. Remember calcuating RMS is to give you the equivalent DC voltage that will cause the same heating effect in a resistor. You can optimise your code to skip the squaring function if the input value is zero to speed things up a little, but you're just saving a multiply (4 cycles) and a 24bit add (~18 cycles). Doing the square root in assembly is not too difficult - it's been done before! Personally I'd do the whole thing in C. |
Topic | Author | Date |
rms value of thyristorised sine wave | 01/01/70 00:00 | |
thyristorised | 01/01/70 00:00 | |
rms value of thyristorised sine wave | 01/01/70 00:00 | |
Calculating RMS | 01/01/70 00:00 | |
Calculating RMS | 01/01/70 00:00 | |
Calculating RMS | 01/01/70 00:00 | |
possible in assembly | 01/01/70 00:00 | |
re: possible in assembly | 01/01/70 00:00 | |
Mistake in logic | 01/01/70 00:00 | |
Mistake in logic | 01/01/70 00:00 | |
? | 01/01/70 00:00 | |
????????????? | 01/01/70 00:00 | |
Fixed Point | 01/01/70 00:00 | |
Answer is wrong | 01/01/70 00:00 | |
Answer is wrong | 01/01/70 00:00 | |
Difficult; Laborious - not impossible | 01/01/70 00:00 | |
Calculating RMS | 01/01/70 00:00 | |
Russell can you send the file please | 01/01/70 00:00 | |
Calculating Square Roots | 01/01/70 00:00 | |
The book was paper! | 01/01/70 00:00 | |
Russell can you send the file please | 01/01/70 00:00 | |
It is supposed to | 01/01/70 00:00 | |
Good Reply | 01/01/70 00:00 | |
Thank you![]() | 01/01/70 00:00 | |
RMS Calculations | 01/01/70 00:00 |