* Your assessment is very important for improving the work of artificial intelligence, which forms the content of this project
Download Sampling And Averaging Considerations For Measuring Input Power
Standby power wikipedia , lookup
Spectral density wikipedia , lookup
Electrification wikipedia , lookup
Power over Ethernet wikipedia , lookup
History of electric power transmission wikipedia , lookup
Power inverter wikipedia , lookup
Three-phase electric power wikipedia , lookup
Chirp spectrum wikipedia , lookup
Voltage optimisation wikipedia , lookup
Electric power system wikipedia , lookup
Power electronics wikipedia , lookup
Amtrak's 25 Hz traction power system wikipedia , lookup
Life-cycle greenhouse-gas emissions of energy sources wikipedia , lookup
Audio power wikipedia , lookup
Power engineering wikipedia , lookup
Buck converter wikipedia , lookup
Utility frequency wikipedia , lookup
Alternating current wikipedia , lookup
Rectiverter wikipedia , lookup
Immunity-aware programming wikipedia , lookup
Switched-mode power supply wikipedia , lookup
Sampling And Averaging Considerations For Measuring Input Power Bob White Staff Engineer Worldwide Technology Group Why Monitor Input Power? ● Improved Facility Utilization – Typical Draw Is 50-70% Of Nameplate Rating – Facilities Planned Based On Nameplate Rating – Can Add 30-80% More Server Capacity Without Additional Facility Capacity ● Important Metric For Virtualization Engines Needed Accuracy ● Revenue Accuracy: ±0.2% To ±0.5% – Not Economical For A Power Supply ● ±10% Not Good Enough – Significant Loss Of Increased Server Capacity – Economical Accuracy One Thing, ● ±5% Better Resolution Another! – Not Quite Good Enough ● OEMs Asking For ±3-4% – Requests For ±1% Have Been Reported Measurement Error: Ideal Measurement Location HVDC+ V LINE FILTER I HVDC– Measurement Error: Actual Measurement Location LINE FILTER HVDC+ V HVDC– V Lots Of Errors In Power Measurement ● Measuring Internally, Not At Power Input ● Component Tolerance Errors – Sense And Amplifier Resistors – Reference Voltages ● A/D Errors – Nonlinearities – Quantization Effects ● Sampling Related Errors Comprehensive Error Analysis Is A Big Job This Presentation Only About Sampling Related Errors Definition Of Power: Periodic Waveform 1 T P = ∫ v(t )i (t )dt T 0 Discrete Time Power Calculation V[5] V[4] V[6] V[3] V[7] V[2] V[8] V[1] V[9] V[0] V[10] TSAMPLE N −1 T/2 TSAMPLE T /2 = N 1 P = ∑ v[k ]i[ k ] N k =0 Discrete Time Power Calculation Discrete Time Power Calculation 7.00E+00 1400 6.00E+00 1200 Discrete Time Sum 1000 4.00E+00 800 3.00E+00 600 Continuous Time Integral 2.00E+00 1.00E+00 400 200 0.00E+00 0 0 1 2 3 4 5 6 7 8 9 10 -1.00E+00 -200 Sample/Time Difference Watts/Volts Joules 5.00E+00 Caveat Emptor ● ● ● ● ● Why Does This Work Out So Nicely? Perfect Sinusoid Fundamental Frequency Only Samples Uniformly Placed Nsamples × Tsample = Period Power Calculation Is Shift Invariant 0 1 2 3 4 5 6 7 8 9 10 7 1400 6 1200 5 1000 Joules 4 Discrete Time Sum 800 3 Continuous Time Integral 2 1 600 400 200 0 0 0 1 2 3 4 5 6 7 8 9 -1 10 -200 Sample/Time Difference Watts/Volts Power Calculation Is Shift Invariant Some Sampling Issues ● How Does The Number Of Samples In a Half Cycle Affect the Error? ● How Much Error Does A Time Difference Between The Voltage And Current Samples Introduce? ● How Much Error Does Not Being To Have An Exact Integer Number Of Samples In a Half Cycle Introduce? ● Does Sampling Over Many Half Cycles Reduce Or Increase The Error? Minimum Two Samples Per Half Cycle ● Two Sample Points Can Have Any Phase Shift And Arithmetic Still Works Minimum Two Samples Per Half Cycle ● Two Sample Points Can Have Any Phase Shift And Arithmetic Still Works ● Special Case: – Sample At Zero Crossing – Sample At The Peak ● Algorithm Is Now Simple ● Find The Peak And Divide By Two ● Just Have To Worry About Error Due To Waveform Distortion Average Power = ½ × Peak Power V And I Sampling Time Difference ● The Least Expense General Purpose Microcontrollers Have: – One A/D Converter – One Sample And Hold Circuit ● Cannot Sample Voltage And Current Simultaneously ● Time Difference Typically 20-40 µs ● Does This Affect Accuracy? ● Note: DSP/DSC Devices May Have More Than One Sample And Hold Circuit VOLTAGE V And I Sampling Time Difference START I SAMPLE CURRENT START V SAMPLE FINISH V SAMPLE FINISH I SAMPLE V And I Sampling Time Difference 0.20 0.1973% 0.10 Error (Joules) 0.00 0.1973% -0.10 -0.20 0 5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 85 90 95 100 -0.30 0 µs -0.40 10 µs 20 µs 50 µs -0.50 100 µs Time (ms) 200 µs Tsample: 500 µs Line Frequency Variations ● Previous Examples Used Calculations Over Exactly One Half Or One Full Cycle Of The Line Frequency ● Consider Line Frequency Variation From 45 Hz To 65 Hz ● One Value Of TSAMPLE Will Not Permit Exact Alignment Over Line Frequency Range Line Frequency Variations: Constant N ● Keep Number Of Samples Per Half Cycle Constant ● Requires: – Detect Zero Crossings – Measuring Period – Adjusting TSAMPLE ● Detecting Zero Crossings Is Resource Intensive Line Frequency Variations: Constant TSAMPLE ● Vary Number Of Samples But Use Constant Sample Rate ● Don’t Have To Detect Zero Crossings Exactly ● Do Have To Figure Out When A Half Cycle Has Passed Line Frequency Variations: Constant TSAMPLE Voltage Past The Half Cycle Peak? Past The Zero Crossing Trough? Voltage Less Than Initial Value? Voltage GTE Initial Value? Line Frequency Variations: Constant TSAMPLE Error S Error As Function Of Line Frequency And Sample Time +12 W –16 W Question ●System Host Sends A READ_PIN Command To A Power Supply ●What Value Does The Power Supply Return? ●A: The Instantaneous V × I At That Moment ●B: The Power Based On The Last Half Cycle ●C: The Power Based On The Last Full Cycle ●D: The Power Averaged Over The Last Several Seconds Average Power Calculation ● Averaging Period (TAVERAGE) From 1 Second To 30 Seconds ● Number Of Half Cycle Values Needed For The Average: – 100 (1 Second, 50 Hz) – 3600 (30 Seconds, 60 Hz) How And When Is This Average Calculated? Possibility 1: Buffer & Calculate On Demand ● Create Circular Buffer This Value With Half CycleThis Power Only Calculations For Averaging Value Period 7 N N3 4 N- N- 5 Bu f Be fer f U p or e dat e fer f u B er Aft te a d p U 1 N- N- 4 5 7 N- 3 N- 2 N- N- N N- 6 2 N- N- Is Updated Too Much Time To Compute The Average 1 ● Update Buffer At Each Does New Half Cycle Not ● CalculateChange On Demand N- 6 N- Possibility 2: Keep A Running Sum Accumulator Always Has The Latest Information Possibility Three: Accumulate And Store ● Accumulator Adds Sample Values For The Averaging Time ● Average Is Calculated ● Average Is Put Into Storage Register, Overwriting Existing Value ● Advantages: – Minimal Hardware – Immediate Response ● Disadvantage: Data Can Be Up To One Averaging Period Old ACCUMULATE COMPUTE AVERAGE STORE IN REGISTER Averaging By Low Pass Filter ● A Low Pass Filter Is Sometimes Mentioned As A Way To Compute Average Power n Bit With MinimalWith Hardware Binary Integer ● A Low Pass Filter Generates A a < 1 Arithmetic: Weighted Average ak < 2-n => 0 a·a = a2 a·a2 = a3 Averaging By Low Pass Filter: Example ● P = 600 W – Constant In Averaging Time ● TAVERAGE = 10 seconds ● FAC = 50 Hz ● NSAMPLES = 1,000 – Summing Half Cycle Power Calculations ● 16 Bits Resolution (n = 16) Averaging By Low Pass Filter: Equations PLPF [n] = 1 N SAMPLES N SAMPLES P ∑ k =0 a k P[n − k ] N SAMPLES PLPF [n] = ∑ ak N SAMPLES Simple IIR k =0 LowNsamples Pass+1Filter a =0 Does Not Work Nsamples −n a = 2 ⇒ a = 0.988967896 PLPF = 54.386 W 600 W Summary ● Discrete Time Calculation Of Power Mostly Straightforward ● Optimizing Sampling Over Variations In Line Frequency Most Significant Challenge ● Averaging Requirements May Make For Expensive Hardware – Caution Is Needed Not To Overspecify