org.bouncycastle.pqc.crypto.mlkem

## Class PolyVec

- java.lang.Object
- - org.bouncycastle.pqc.crypto.mlkem.PolyVec

-     class PolyVec
      extends Object

  Vector of polynomials for ML-KEM operations. Provides operations on collections of polynomials used in lattice cryptography.

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `(package private) Poly[]` | `vec`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `PolyVec()`
    `PolyVec(MLKEMEngine engine)`

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `void` | `addPoly(PolyVec b)`
    `byte[]` | `compressPolyVec()`
    `void` | `conditionalSubQ()`
    `void` | `decompressPolyVec(byte[] compressedPolyVecCipherText)`
    `void` | `fromBytes(byte[] inputBytes)`
    `Poly` | `getVectorIndex(int i)`
    `static void` | `pointwiseAccountMontgomery(Poly out, PolyVec inp1, PolyVec inp2, MLKEMEngine engine)`
    `void` | `polyVecInverseNttToMont()`
    `void` | `polyVecNtt()`
    `void` | `reducePoly()`
    `byte[]` | `toBytes()`
    `String` | `toString()`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

- - ### Field Detail

    - #### vec

          Poly[] vec

  - ### Constructor Detail

    - #### PolyVec

          public PolyVec()
                  throws Exception

      Throws:
        `Exception`

    - #### PolyVec

          public PolyVec(MLKEMEngine engine)

  - ### Method Detail

    - #### addPoly

          public void addPoly(PolyVec b)

    - #### compressPolyVec

          public byte[] compressPolyVec()

    - #### conditionalSubQ

          public void conditionalSubQ()

    - #### decompressPolyVec

          public void decompressPolyVec(byte[] compressedPolyVecCipherText)

    - #### fromBytes

          public void fromBytes(byte[] inputBytes)

    - #### getVectorIndex

          public Poly getVectorIndex(int i)

    - #### pointwiseAccountMontgomery

          public static void pointwiseAccountMontgomery(Poly out,
                                                        PolyVec inp1,
                                                        PolyVec inp2,
                                                        MLKEMEngine engine)

    - #### polyVecInverseNttToMont

          public void polyVecInverseNttToMont()

    - #### polyVecNtt

          public void polyVecNtt()

    - #### reducePoly

          public void reducePoly()

    - #### toBytes

          public byte[] toBytes()

    - #### toString

          public String toString()

      Overrides:
        `toString` in class `Object`