Quadratic Residue Calculator
Determine if a number is a quadratic residue modulo p and find its square roots.
Enter Values
Definition
An integer a is a quadratic residue modulo n if:
x^2 ≡ a (mod n)
has a solution for some integer x.
Euler's Criterion
For odd prime p and gcd(a, p) = 1:
a^((p-1)/2) ≡ 1 (mod p) iff a is QR
Is 3 a Quadratic Residue mod 13?
YES
Legendre symbol: (3/13) = 1
Modulus Type
Prime
# QR (excl. 0)
6
Square Roots
Solutions to x^2 ≡ 3 (mod 13):
x = 4x = 9
Quadratic Residues mod 13
13491012
Non-Residues mod 13
2567811
💡
Help us improve!
How would you rate the Quadratic Residue Calculator?
Editorial Note
MyCalcBuddy Editorial Team
This page is maintained as an educational calculator reference.
📚
Formula Source: Handbook of Mathematical Functions
by Abramowitz & Stegun
🔄Last reviewed: May 2026
✓Formula checks are based on standard references and internal QA review.