Template Function lbcrypto::Degree
Defined in File ckksrns-utils.h
Function Documentation
-
template<typename VecDType>
uint32_t lbcrypto::Degree(const std::vector<VecDType> &coefficients, double delta = 0.0) Gets the degree of a polynomial specified by its coefficients, which is the index of the last non-zero element in the coefficients. If all the coefficients are zero, it returns 0.
- Parameters
coefficients – vector of coefficients of a polynomial (can not be empty)
- Returns
the integer degree of the polynomial.