Commit 65d72786 authored by Sven Liefgen's avatar Sven Liefgen
Browse files

Fix vdmcoder not being able to inverse matrix

The inverse table for the galois field was missing the last value and
thus was always set to 0, which could result in a 0-column/row in the
matrix, making it not inversible.
parent da1eb5a3
Pipeline #4768 failed with stages
in 26 seconds
......@@ -82,7 +82,7 @@ fn generate_field() -> String {
// 0 has no inverse
inverse[0] = 0;
inverse[1] = 1;
for i in 2..GF_SIZE {
for i in 2..=GF_SIZE {
inverse[i] = exp[GF_SIZE - log[i] as usize];
let mut result = String::new();
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment