|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectjist.swans.radio.BERTable
public class BERTable
Implementation of Bit-Error-Rate calculations (via a loaded table) for a range of Signal-to-Noise-Ratio values.
| Field Summary | |
|---|---|
private double[] |
ber
Table with Bit-Error-Rate values for given Signal-to-Noise-Ratio values. |
private double[] |
snr
Table with Bit-Error-Rate values for given Signal-to-Noise-Ratio values. |
| Constructor Summary | |
|---|---|
BERTable(java.lang.String filename)
Initialize the BER table with data from given file. |
|
| Method Summary | |
|---|---|
double |
calc(double snrVal)
Compute BER value by interpolating among existing SNR points. |
private void |
check()
Verify the input data. |
private void |
load(java.io.File f)
Load BER data from a given file. |
boolean |
shouldDrop(double snrVal,
int bits)
Compute probabilistically whether an error occured for a given number of bits and SNR value. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private double[] snr
private double[] ber
| Constructor Detail |
|---|
public BERTable(java.lang.String filename)
throws java.io.IOException
filename - file to load
java.io.IOException - unable to read BER file| Method Detail |
|---|
private void load(java.io.File f)
throws java.io.IOException
f - BER data file
java.io.IOException - unable to read BER fileprivate void check()
public double calc(double snrVal)
snrVal - input SNR value for BER computation (interpolation)
public boolean shouldDrop(double snrVal,
int bits)
snrVal - Signal-to-Noise-Ratio valuebits - number of bits
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||