Documentation

QuadExpr.getCoeff()


QuadExpr.getCoeff()

getCoeff ( i )

Retrieve the coefficient from a single term of the expression.

Return value:

Coefficient for the quadratic term at index i in the expression.

Example usage:

  expr = x * x + 2 * y * y + z
  print(expr.getCoeff(1))