HashMap<Integer, Integer> syndromesToAlphaPowers = new HashMap<>();
boolean errors = false;
//Poszukiwanie syndromow S(1) - S(2T)
for (int i = 1; i <= 2 * getCode().getT(); i++) {
BinPolynomial currSyndrom = new BinPolynomial(0);
for (int j = 0; j < getCode().getN(); j++) {
//S(i) = R(j) * (S(i) + alfa(i*j))
if (input.getCoefficient(j)) {
currSyndrom = currSyndrom.add(gf.getAlpha((i * j) % getCode().getN()));
}
}
//Czy sa bledy
if (currSyndrom.getPolyVector().compareTo(BigInteger.ZERO) != 0) {
errors = true;
}
//Zapis potegi alfy zgodnej z syndromem na pozycji i-tej
syndromesToAlphaPowers.put(i, gf.getPower(currSyndrom));
}