Recently while reviewing an instrument, I came across an error message which I did not expect – “unable to detect line frequency”. This, along with other curiosities, prompted me to investigate my mains power quality. For example, how has the relatively recent widespread adoption of grid-connected photovoltaic systems affected my power quality, has my grid voltage changed at all since the last analysis in 2018, what is the off-peak ripple signalling like around the clock, is there any pattern to harmonic magnitudes/frequencies and more.
Power Quality Methodology
Luckily for me, I have a Tektronix PA1000 Power Analyzer and a B&K Precision DAS240-BAT Multi-Channel Recorder from previous RoadTests to help me out. Using a Python program that melded SCPI with Modbus TCP, I decided to log voltage, frequency, crest factor, harmonic magnitude/phase (1-50) and solar insolation (relative) for a period of about 15 days, collecting a total of 2,763,780 data samples which occupied 2.82GB of storage.
The power quality was measured from a GPO with no other load connected in adjacent sockets to reduce the effect of localised load changes affecting readings. The solar insolation was determined with a 1.5V/500mA solar “hobby” cell with a 1-ohm resistor shorting over the terminals. The developed voltage indicates the (near) short circuit current which should be proportional to the incoming solar radiation. The cell was placed in an upstairs window with a northward facing aspect at the optimum tilt angle which simulates the output expected from grid-connected PV systems with a similar orientation (which is the majority, but not all).
Power Quality ‘101’ Metrics
The first thing to check is the basics – the “101s” of power quality.
VOLTS FREQUENCY CREST FACTOR Max 260.18 50.230 1.5865 Min 236.98 49.721 1.3627 Range 23.20 0.509 0.2238 Mean 247.5865 50.0000 1.3801 Median 247.61 50.0000 1.3800 StDev 1.8415 0.0535 0.0046
Compared to my last attempt, I’ve collected a lot more data points and the results seem a little interesting. For one, the mean voltage has gone up by about 2.1V, while the crest factor average has gone up by 0.002176 which is insignificant. Since more data is collected, the frequency mean and median are right on 50Hz, as it should be.
The mains voltage is a bit on the high side, measuring about 247.6V on average. The maximum registered voltage of 260.18V is 13.1% over the 230V nominal, just slightly less than the 264V “high limit” although this is likely to just be a very “short” term reading as it is not averaged over ten minutes as usually needed by the standards documents. Perhaps some histograms would be helpful.
Image may be NSFW.
Clik here to view.
On a linear scale, we can see the voltage is a sort of “flat-topped” bell curve … similar to the flat-topped sine wave which is the “norm”. There doesn’t seem to be much in the way of skew. The double-peak I saw last time is still sort of there, but the “dip” in-between is filled in.
Image may be NSFW.
Clik here to view.
Plotting the same thing using a logarithmic vertical scale allows for seeing some of the lower frequency bins. It seems that isolated clusters of higher voltage are more likely than the small isolated clusters of lower (but still very much acceptable) voltage events. This is perhaps not good news – excessive voltages can cause some appliances to consume more energy and shorten their lifetime (e.g. a capacitive dropper’s shunt regulation zener would put out more heat and reduce its operational lifetime).
Image may be NSFW.
Clik here to view.
The frequency histogram is not quite as neatly a bell curve, with some bias towards lower frequencies it seems.
Image may be NSFW.
Clik here to view.
This is made more apparent by the log-axis version of the graph, however, as expected the regulation must be quite tight for the grid to work properly, so the result is basically what we expect.
Image may be NSFW.
Clik here to view.
I plotted the crest factor histogram with a more limited range than the full range of data. There is a clustering around 1.38, which is far from the 1.414.. ideal value.
Image may be NSFW.
Clik here to view.
The log-plot shows us that the crest factor “highs” are usually infrequent isolated events, which may arise due to mains waveform distortion caused by switching of loads.
Image may be NSFW.
Clik here to view.
The crest factor versus time graph shows clearly how there are spikes in the graph, likely to be switching events, but the crest factor seems to follow a daily trend pattern which seems to imply that the crest factor is falling as the grid load increases and increasing during the hours of light load (i.e. sleeping hours).
Tektronix PA1000 vs AEMO?
I recently discovered that AEMO’s site actually has a publicly downloadable weekly report that contains the grid frequency measured every four seconds. I thought it would be fun to just download this data, linearly-interpolate between the four second points and compare what the difference in the PA1000’s figures and AEMO’s figures are. I compared the values for 1,039,879 samples from the PA1000 which overlap the data available from AEMO (as they’re behind by a week usually).
Image may be NSFW.
Clik here to view.
I don’t expect a direct correspondence as the linear interpolation between provided data-points is not going to be 100% accurate, and the data from AEMO is at a much higher numerical resolution than that offered by the PA1000. Regardless, it’s nice to see a bell-curve which is centred around zero error – what I’d expect to see if the power analyzer is accurate.
Image may be NSFW.
Clik here to view.
The unit’s accuracy stated as 0.05Hz, while the absolute difference topped out at under 0.3Hz. It’s likely infrequent local distortion or interpolation errors for step changes in grid frequency would be the reason for the significant differences there. I’d say the PA1000 is decently accurate – not GPS accurate, but good enough for basic measurements.
Harmonic Magnitude and Phase
The Tektronix PA1000 offers the ability to record the 1st to 50th harmonic magnitude and phase angle. I wondered if there’s any particular pattern to the distortion on the line, so I collected data across all days and summarised it in two histograms. The histograms begin with the 1st harmonic in the top left, 50th in the bottom right, read left to right (1…10, 11…20, etc).
Image may be NSFW.
Clik here to view.
The harmonic magnitude histogram shows that for the vast majority of even harmonics, the magnitude is essentially negligible while odd harmonics tend to show some significant values up to around the 13th harmonic with smaller values from there. Some of the odd harmonics show a double-peak in the voltage distribution which suggests perhaps some time-varying result – expected due to the crest factor versus time finding earlier.
Image may be NSFW.
Clik here to view.
As for the phase, it seems that even harmonics show only small amounts of phase relationship with the fundamental, whereas odd harmonics of the lower orders generally have a strong phase relationship. Ultimately, with this data, it can be possible to generate a rough approximation of the mains waveform (which is used by Tektronix PWRVIEW), but if anything, I just did it out of curiosity and for the pretty plots.
Zellweger K22/Decabit Mains Ripple Injection Signalling
Around my area, 1050Hz mains ripple injection off-peak signalling is used which is a bit of a nuisance. I’ve suspected it to be too high in amplitude but I’ve only really only done spot checks. Now that I’ve got the full harmonic data from the PA1000, it is possible to see how the ripple injection (21st harmonic) varies over the course of all logged data (note, the gap is due to a crash of recording equipment).
Image may be NSFW.
Clik here to view.
The ripple injection signal strength varies as a function of time of day. At times, it reaches 21Vrms, which is on the high side, while others, it may sit at about 9Vrms which is about right. This seems to illustrate what a difference load on the network makes to the strength of the signal – perhaps the network resonates with certain loads more than others. There also was a period where some uncharacteristic 21st harmonic noise seems to have been recorded – quite strange indeed.
I suspect powering on my instrument at the time a strong ripple injection burst was running was the cause of the “unable to detect mains frequency” error, as the signal would have caused simple zero-crossing detectors to fire many more times than expected and at an erratic pace as well.
Grid-Connected Solar Influences
This now leads me to another curiosity – has the recent installation of grid-connected photovoltaics systems really affected the grid much in my area. I note that the voltage seems to have increased slightly which may make exporting to the grid more difficult, but is grid-connected PV to blame.
Image may be NSFW.
Clik here to view.
To find out, I decided to plot the raw data versus my “reference” solar panel as described in the methodology section. Over the days surveyed, there were a number of clear days initially, followed by cloudy and partly cloudy days which should give some distribution of data to work with. This panel was facing north, but not all systems would be facing north, so there isn’t going to be a perfect correlation.
Image may be NSFW.
Clik here to view.
A scatter-plot of the line voltage versus solar current seems to show no obvious relationship – thus it seems that whatever voltages I’m receiving may not be entirely due to the installation of grid-connect systems by my neighbours, but merely a side effect of how mains voltage is regulated in my area.
Image may be NSFW.
Clik here to view.
Another thing I wondered was whether there was any harmonic distortion effects of the inverters on the local grid. This is hard to determine but there seemed to be a small decrease in crest factor with increasing solar current. This is not proof, however, as the crest factor is seen to decrease during daylight hours perhaps due to the change in load pattern as well.
Image may be NSFW.
Clik here to view.
Looking at the third-harmonic magnitude, not much seems to change as a function of solar current.
Image may be NSFW.
Clik here to view.
However, the fifth harmonic seems to have some sort of correlation. An interesting (to me), albeit, meaningless finding.
Switching of Appliances
This brings me to another mains-related thing, so I thought I’d lump it in with this post. For a long time, I’ve lumped my instrument “rack” together onto a remote switch for energy saving and safety reasons. However, since each of these instruments usually have some form of capacitive line filter or a switchmode supply in them, switching these instruments can be quite hard on the relay due to inrush current which usually results in audible interference (e.g. a pop) from mains-powered speakers around the house.
I thought it would be interesting to see just how much of an effect the inrush current of switching my instrument rack has on my “local” power. To do this, I used my two high-voltage differential probes and my Rohde & Schwarz RTM3004 oscilloscope.
Image may be NSFW.
Clik here to view.
The first thing to check was the skew between the two probes. Connected to the same 1kHz source, the Micsig was marginally faster perhaps, but not by more than perhaps 5ns. Not enough of a difference to be a problem for this investigation.
Image may be NSFW.
Clik here to view.
Channel 1 is connected to the power at the instrument rack, while Channel 2 is connected to the supply side of the remote switch. At this point, switching the remote switch causes a short momentary dip in mains voltage by about 70V. This rapid “step” change contains many harmonics, thus, I suspect this is why amplifiers and speakers may pass a “pop” noise as it might not be filtered out.
Image may be NSFW.
Clik here to view.
Of course, the magnitude of the effect does depend on where in the sine wave the switching happens. This next attempt was a very similar result, but before the zero crossing, so we can see the effect of charging up the capacitors causes the voltage at the instrument rack to take about 2ms to rise to track the incoming power.
Image may be NSFW.
Clik here to view.
The supply side seems to have suffered a disruption measuring about a 60V dip, with the full recovery off the screen.
Image may be NSFW.
Clik here to view.
Switching near the peak of the sine wave makes things appear somewhat worse.
Image may be NSFW.
Clik here to view.
This time, the disruption is about 200V lasting about 0.8ms to fully recover. I can’t tell what the inrush current is without knowing the impedances involved, but it’s a clear sign of just how even switching appliances which are “turned off” could be quite hard on relays. I’ve had some of these remote switches “weld” their relay contacts as a result. I suppose this is why higher-quality switches may have snubber networks across the relays to protect against inrush-related damage.
Conclusion
This was a bit of a random mixed-bag of mains-power related experiments, inspired by an error message I received from an instrument and by my general curiosity. It seems that the mains voltage in my area has gone up slightly, while grid-connected photovoltaic systems don’t appear to be the cause. Ripple signalling in my area, however, is quite strong when the grid is lightly loaded which seems likely to be the cause of the error message I received. I also managed to take a look at the harmonic magnitude and phase information – most of the interesting stuff seems to be in the odd harmonics which are more significant in magnitude and show a single or dual-peak phase-relationship with the fundamental. Finally, switching appliances (even when they are turned off) using relay-based remote switches can be quite savage due to the inrush current of multiple mains filters and switch-mode supplies in parallel which can be the cause of relay welding.