Resolution to #7
Fault in gf256 multiply function. Atom removed a bunch of trailing spaces, so these are in here too.
This commit is contained in:
parent
9da3a8d73c
commit
6eb5d48faf
@ -83,10 +83,10 @@ subtract(F = #gf256{}, A, B) ->
|
|||||||
add(F, A, B).
|
add(F, A, B).
|
||||||
|
|
||||||
%%
|
%%
|
||||||
multiply(#gf256{}, 1, B) ->
|
multiply(#gf256{}, 0, _) ->
|
||||||
B;
|
0;
|
||||||
multiply(#gf256{}, A, 1) ->
|
multiply(#gf256{}, _, 0) ->
|
||||||
A;
|
0;
|
||||||
multiply(F = #gf256{}, A, B) ->
|
multiply(F = #gf256{}, A, B) ->
|
||||||
X = (log(F, A) + log(F, B)) rem ?RANGE,
|
X = (log(F, A) + log(F, B)) rem ?RANGE,
|
||||||
exponent(F, X).
|
exponent(F, X).
|
||||||
|
Loading…
Reference in New Issue
Block a user