( _poly: Expression, _vars: string | string[] )
| 40 | // ==================== POLYNOMIAL ARITHMETIC ==================== |
| 41 | // |
| 42 | |
| 43 | /** |
| 44 | * Get the degree of a polynomial in a specific variable. |
| 45 | * Returns -1 if the expression is not a polynomial in the variable. |
| 46 | * |
| 47 | * Examples: |
| 48 | * - `polynomialDegree(x^3 + 2x + 1, 'x')` → 3 |
| 49 | * - `polynomialDegree(x*y + y^2, 'x')` → 1 |
| 50 | * - `polynomialDegree(sin(x), 'x')` → -1 (not a polynomial) |
| 51 | */ |
nothing calls this directly
no test coverage detected