We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent fbcd5d4 commit e638fc3Copy full SHA for e638fc3
src/tables.jl
@@ -1,7 +1,7 @@
1
2
function computetables(exponents::Matrix{T}) where {T<:Integer}
3
m, n = size(exponents)
4
- lookuptable = exponents'
+ lookuptable = permutedims(exponents, (2, 1))
5
6
for j=1:m
7
sort!(@view lookuptable[:, j])
@@ -29,7 +29,7 @@ function computetables(exponents::Matrix{T}) where {T<:Integer}
29
differences[i, j] = lookuptable[j, i]
30
end
31
32
- lookuptable = reshape(lookuptable, (m, n))
+ lookuptable = permutedims(lookuptable, (2, 1))
33
for j=1:n, i=1:m
34
for k = 1:maxk
35
if differences[i, k] == exponents[i, j]
0 commit comments