PolyVecMatrix
class PolyVecMatrix
namespace Org.BouncyCastle.Pqc.Crypto.Crystals.Dilithium
{
internal class PolyVecMatrix
{
private readonly PolyVec[] m_matrix;
public PolyVecMatrix(DilithiumEngine engine)
{
int k = engine.K;
int l = engine.L;
m_matrix = new PolyVec[k];
for (int i = 0; i < k; i++) {
m_matrix[i] = new PolyVec(engine, l);
}
}
public void ExpandMatrix(byte[] rho)
{
for (int i = 0; i < m_matrix.Length; i++) {
m_matrix[i].UniformBlocks(rho, i << 8);
}
}
public void PointwiseMontgomery(PolyVec t, PolyVec v)
{
for (int i = 0; i < m_matrix.Length; i++) {
t[i].PointwiseAccountMontgomery(m_matrix[i], v);
}
}
}
}