mirror of
https://github.com/aicodix/code.git
synced 2026-04-27 22:35:44 +00:00
keep ranges symmetric
This commit is contained in:
parent
b146d9739a
commit
7e589c85ef
7 changed files with 10 additions and 10 deletions
|
|
@ -115,7 +115,7 @@ int main()
|
|||
double DIST = 2; // BPSK
|
||||
double fact = DIST / (sigma_noise * sigma_noise);
|
||||
for (int i = 0; i < N; ++i)
|
||||
noisy[i] = std::min<double>(std::max<double>(std::nearbyint(fact * symb[i]), -128), 127);
|
||||
noisy[i] = std::min<double>(std::max<double>(std::nearbyint(fact * symb[i]), -127), 127);
|
||||
|
||||
osddec(rank, decoded, noisy, genmat);
|
||||
bool unique = rank[0] != rank[1];
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue