Skip to main content

bpsk

Function bpsk 

Source
pub fn bpsk(bits: &[u8]) -> Vec<f64>
Expand description

The real BPSK symbols $1 - 2b$ of bits ($0 \mapsto +1$, $1 \mapsto -1$), the modulation of the code tests over a real channel (crate::demapper::bpsk_llr is its demapper).

ยงExamples

use comnum_mapping::constellation::bpsk;
assert_eq!(bpsk(&[0, 1, 1]), [1.0, -1.0, -1.0]);