IsQuadraticIrrational
True when is an irrational root of a quadratic with integer coefficients — exactly the numbers with an eventually periodic continued fraction.
✓ checked against that system · ! checked, with disagreements (hover a chip)Wolfram Language
QuadraticIrrationalQ✓IsQuadraticIrrational(x)whether is a quadratic irrationalTyped signatures
| Type | Package | Applies |
|---|---|---|
(value) -> boolean | modular | always |
Details
- Recognised structurally: a rational affine combination with exactly one irrational
Sqrtterm, at any rational scale — , , , , - A rational is not irrational, so it is
False, not merely unrecognised - Wolfram calls this
QuadraticIrrationalQ; the name here follows compute-engine's ownIs…convention instead - Every quadratic irrational's continued fraction is eventually periodic (Lagrange's theorem), and conversely — see ContinuedFraction
Examples
About
| Examples | 14 |
|---|---|
| Checked against | Wolfram Language 14 agree |
| Crosswalk | Wolfram Language |
See also: ContinuedFraction, Convergents