====== Determining SNR and sensitivity ====== ===== How to measure the noise ===== After calibrating the (not bandpass-corrected) baseline visibilities for phases determined from the fringe-fitting result, we determine the final bandpass by vector-averaging per channel and polarisation. The data are divided by this bandpass, so that they are unity on average and deviations are only due to residual calibration problems and due to thermal noise. We can now determine the rms deviation from 1 (separately for real and imaginary part) in several ways: ^ no ^ name ^ description ^ | 0 | rms | rms deviation from 1 | | 1 | diff in time | from difference between adjacent time bins | | 2 | diff in freq | from difference between adjacent channels | | 3 | symmetric diff in time | from difference to mean of both adjacent time bins | | 4 | symmetric diff in freq | from difference to mean of both adjacent channels | | 5 | weights | from ''WEIGHT_SPECTRUM'', derived from autocorrelations, dt*df/(auto1*auto2) | | 6 | rms2 | rms deviation from frequency-average (per time and pol) | The correct scaling factors are applied in all cases. For "diff in freq" the difference between channels 0 and 1 is used for 0 etc, the last one is assigned zero. For "symmetric diff in freq" the first and last are assigned zero. The option "weights" is included for comparison, it defines the theoretical limit for perfect correlator efficiency and calibration (perfect coherence). What we measure is the noise per time/frequency bin. This has to be translated to SEFD-like quantites per original sample by multiplying with sqrt (channel-width*integration-time). These procedures have different advantages and disadvantages. The "rms" is very simple, but only accurate if the calibration works perfectly, because otherwise residual calibration errors are misinterpreted as thermal noise. The option "rms2" works slightly better. The differences are generally less affected by calibration problems. The more channels we have, the higher is the thermal noise relative to calibration residuals, so that the accuracy increases. From this we get several versions (real/imag for each of the 5 procedures) of noise-to-signal (N/S). If we multiply with the calibrator flux per channel, we obtain the SEFD for the baseline. To a very good approximation this is a factor of sqrt (2) smaller than the SEFD of individual stations (or the geometric mean of both SEFDs if they are different), as we will see below. Note that real and imaginary part are affected by different calibration problems: real more by amplitude and imag more by phase ===== Baseline noise ===== If the SEFDs of two stations are N1 and N2 and the source flux is S, we can derive the following noise quantities: ^ quantity ^ value ^ | noise in 1 | N1+S | | noise in 2 | N2+S | | noise in baseline 1-2, real | sqrt { [ (N1+S)*(N2+S) + S*S ] / 2 } | | noise in baseline 1-2, imag | sqrt { [ (N1+S)*(N2+S) - S*S ] / 2 } | For PKS 1934-638 we have a flux of roughly S=10Jy, the SEFD is about 500Jy. If we completely neglect the source flux, we have: ^ quantity ^ value ^ | noise in 1 | N1 | | noise in 2 | N2 | | noise in baseline 1-2, real or imag | sqrt ( N1*N2 / 2 ) | If we take S into account to first order for the baseline, we find: ^ quantity ^ value ^ | noise in baseline 1-2, real or imag | sqrt { [ N1*N2 + S*(N1+N2) ] / 2 } | Even for high S we can combine the real and imaginary noise (if we can trust both) to find that the sum of squares of both is (N1+S)*(N2+S). This can be separated to get the station-based N+S values, from which we can determine the individual SEFD = (N+S) - S. Remember that our calibration procedure provides not the noise itself, but the noise divided by the signal. ===== Calibrators ===== If we want to translate SNRs into SEFDs, we have to know the absolute flux (or spectrum) of the calibrator. For PKS 1934-638 we use the [[http://www.atnf.csiro.au/observers/memos/d96783~1.pdf|Reynolds (1994)]] flux model. Note that this differs considerably from the MeerKAT model as defined by the source description ''J1939-6342 | PKS 1934-63, radec delaycal bpcal, 19:39:25.03, -63:42:45.7, (200.0 12000.0 -11.11 7.777 -1.231)''. {{:projects:mkat_sband:pub:pks1934_flux.png?direct&400}} ===== Tests ===== Let us try these different procedures with dataset (see [[projects:mkat_sband:pub:imobs_list|the list]]) 1603186576, which is one hour on PKS~1934-638 in 4k mode in band S3. We fringe-fit over 1/10/60-sec blocks. As example we use the baseline m045-m060, because it has quite strong phase fluctuations. Only the first pol is shown. To help distinguishing the different methods, we average the noise-to-signal over 64 channels each. The real part is plotted with solid lines, the imaginary part is dotted. 60-sec solutions:\\ {{:projects:mkat_sband:pub:snr_60sec.png?direct&400}} 10-sec solutions:\\ {{:projects:mkat_sband:pub:snr_10sec.png?direct&400}} 1-sec solutions:\\ {{:projects:mkat_sband:pub:snr_1sec.png?direct&400}} Particularly in the 60-sec solution we find that the "rms" method does not work well. For 10-sec and 1-sec, everything gets closer together. In these cases the "diff in freq" and "symmetric diff in freq" methods are both very good and almost indistinguishable. For the future we will generaly use "symmetric diff in freq" with 1-sec solution intervals, unless noted otherwise. Using the "symmetric diff in freq" result (and "weights" for comparison) and combining the real and imaginary parts as mentioned, we can (under the assumption that both stations are equal) determine the SEFD+S and the SEFD from this baseline. In the following plot we binned over 16 channels each: \\ {{:projects:mkat_sband:pub:sefd_1sec.png?direct&500}} The SNR can be reduced or separated into station-based SNRs, as shown with the dashed yellow lines. These can hardly be distinguished from the solid (baseline-based) lines, which proves that the separation works well.