Gauss sum
If we let "q" = 1, the identity reduces to a formula for the quadratic Gauss sum modulo "p".