static sdr.ReplicaCorrelator.roc(enr: float, p_fa: ArrayLike | None = None, complex: bool = True) tuple[NDArray[float64], NDArray[float64]]

Computes the receiver operating characteristic (ROC) curve.

Parameters:
enr: float

The received energy-to-noise ratio \(\mathcal{E}/\sigma^2\) in dB.

p_fa: ArrayLike | None = None

The probability of false alarm \(P_{fa}\). If None, the ROC curve is computed for p_fa = np.logspace(-10, 0, 101).

complex: bool = True

Indicates whether the signal is complex.

Returns:

  • The probability of false alarm \(P_{fa}\).

  • The probability of detection \(P_d\).

Examples

In [1]: plt.figure(); \
   ...: sdr.plot.roc(*sdr.ReplicaCorrelator.roc(-10), label="ENR = -10 dB"); \
   ...: sdr.plot.roc(*sdr.ReplicaCorrelator.roc(-5), label="ENR = -5 dB"); \
   ...: sdr.plot.roc(*sdr.ReplicaCorrelator.roc(0), label="ENR = 0 dB"); \
   ...: sdr.plot.roc(*sdr.ReplicaCorrelator.roc(5), label="ENR = 5 dB"); \
   ...: sdr.plot.roc(*sdr.ReplicaCorrelator.roc(10), label="ENR = 10 dB"); \
   ...: sdr.plot.roc(*sdr.ReplicaCorrelator.roc(15), label="ENR = 15 dB");
   ...: 
../../_images/sdr_ReplicaCorrelator_roc_1.png