R0047-24156 · q-20261015-advance-20261113-r04-euler-criterion-quadratic-residue-0031
Step-by-step derivation
S001 · implies
Before
source roles = [eulercrit-independent-comparison]
After
derived = [[prime, normalized_class, nonzero_roots, Legendre_symbol, modular_power, signed_power, equal, certificate]]
Conditions: none
List the source field order without JavaScript.Gradient boundary uses its original mode to choose6,8 or7 fields;no padding or answer-derived mode.
Step identifiers and dependencies
Rule: source_ordered_fields_without_JS · Uses: G001
S002 · implies
Before
source roles = [17]
After
derived = [[[2, 1], [3, 2], [4, 1]], Yes]
Conditions: none
A composite has a factor at most its square root;complete trial division qualifies the modulus,not a guessed square/Euler equality.
Step identifiers and dependencies
Rule: Euler_modulus_primality_complete_trial · Uses: G001, S001
S003 · calculation
Before
Euler ORIGINAL signed quotient times modulus := mul(0, 17)
After
Euler ORIGINAL signed quotient times modulus = 0
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S002
S004 · calculation
Before
Euler ORIGINAL signed a minus modulus multiple := sub(6, 0)
After
Euler ORIGINAL signed a minus modulus multiple = 6
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S003
S005 · implies
Before
source roles = [6, 17, 0]
After
derived = [6, Yes]
Conditions: none
Use a=qp+r with0<=r<p,including negative a;retain original a where the interface requests it.
Step identifiers and dependencies
Rule: Euler_Euclidean_class_before_hypothesis · Uses: G001, S004
S006 · implies
Before
source roles = [17, 6, 6]
After
derived = [Yes, Yes]
Conditions: none
Qualify odd primality and the nonzero class first.Define Legendre by the square table before comparing a power.
Step identifiers and dependencies
Rule: Euler_odd_prime_nonzero_qualified · Uses: G001, S005
S007 · calculation
Before
Euler square root candidate1 := mul(1, 1)
After
Euler square root candidate1 = 1
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S006
S008 · calculation
Before
Euler square root candidate2 := mul(2, 2)
After
Euler square root candidate2 = 4
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S007
S009 · calculation
Before
Euler square root candidate3 := mul(3, 3)
After
Euler square root candidate3 = 9
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S008
S010 · calculation
Before
Euler square root candidate4 := mul(4, 4)
After
Euler square root candidate4 = 16
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S009
S011 · calculation
Before
Euler square root candidate5 := mul(5, 5)
After
Euler square root candidate5 = 25
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S010
S012 · calculation
Before
Euler square root candidate6 := mul(6, 6)
After
Euler square root candidate6 = 36
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S011
S013 · calculation
Before
Euler square root candidate7 := mul(7, 7)
After
Euler square root candidate7 = 49
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S012
S014 · calculation
Before
Euler square root candidate8 := mul(8, 8)
After
Euler square root candidate8 = 64
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S013
S015 · calculation
Before
Euler square root candidate9 := mul(9, 9)
After
Euler square root candidate9 = 81
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S014
S016 · calculation
Before
Euler square root candidate10 := mul(10, 10)
After
Euler square root candidate10 = 100
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S015
S017 · calculation
Before
Euler square root candidate11 := mul(11, 11)
After
Euler square root candidate11 = 121
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S016
S018 · calculation
Before
Euler square root candidate12 := mul(12, 12)
After
Euler square root candidate12 = 144
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S017
S019 · calculation
Before
Euler square root candidate13 := mul(13, 13)
After
Euler square root candidate13 = 169
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S018
S020 · calculation
Before
Euler square root candidate14 := mul(14, 14)
After
Euler square root candidate14 = 196
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S019
S021 · calculation
Before
Euler square root candidate15 := mul(15, 15)
After
Euler square root candidate15 = 225
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S020
S022 · calculation
Before
Euler square root candidate16 := mul(16, 16)
After
Euler square root candidate16 = 256
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S021
S023 · implies
Before
source roles = [17, 6]
After
derived = [[[1, 1], [2, 4], [3, 9], [4, 16], [5, 8], [6, 2], [7, 15], [8, 13], [9, 13], [10, 15], [11, 2], [12, 8], [13, 16], [14, 9], [15, 4], [16, 1]], [], -1]
Conditions: none
Enumerate every nonzero square;roots give+1 and complete absence gives−1.This route does not use Euler criterion to compute Legendre.
Step identifiers and dependencies
Rule: Euler_ALL_nonzero_square_table_defines_Legendre · Uses: G001, S022
S024 · calculation
Before
Euler binary power square0 := mul(6, 6)
After
Euler binary power square0 = 36
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S023
S025 · implies
Before
source roles = [0, [1, 6, 8], 17, 6, 8]
After
derived = [null, 36, 1, 2, 4]
Conditions: none
Maintain acc*base^remaining congruent to the original half-power:accumulate an odd bit,square the base,and halve the exponent to0.This is separate from the square-table calculation.
Step identifiers and dependencies
Rule: Euler_repeated_squaring_original_exponent_invariant · Uses: G001, S024
S026 · calculation
Before
Euler binary power square1 := mul(2, 2)
After
Euler binary power square1 = 4
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S025
S027 · implies
Before
source roles = [1, [1, 2, 4], 17, 6, 8]
After
derived = [null, 4, 1, 4, 2]
Conditions: none
Maintain acc*base^remaining congruent to the original half-power:accumulate an odd bit,square the base,and halve the exponent to0.This is separate from the square-table calculation.
Step identifiers and dependencies
Rule: Euler_repeated_squaring_original_exponent_invariant · Uses: G001, S026
S028 · calculation
Before
Euler binary power square2 := mul(4, 4)
After
Euler binary power square2 = 16
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S027
S029 · implies
Before
source roles = [2, [1, 4, 2], 17, 6, 8]
After
derived = [null, 16, 1, 16, 1]
Conditions: none
Maintain acc*base^remaining congruent to the original half-power:accumulate an odd bit,square the base,and halve the exponent to0.This is separate from the square-table calculation.
Step identifiers and dependencies
Rule: Euler_repeated_squaring_original_exponent_invariant · Uses: G001, S028
S030 · calculation
Before
Euler binary power accumulate3 := mul(1, 16)
After
Euler binary power accumulate3 = 16
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S029
S031 · calculation
Before
Euler binary power square3 := mul(16, 16)
After
Euler binary power square3 = 256
Conditions: none
Substitute original roles and established intermediates exactly;check nonzero denominators and do not round.
Step identifiers and dependencies
Rule: exact_rational_arithmetic · Uses: G001, S030
S032 · implies
Before
source roles = [3, [1, 16, 1], 17, 6, 8]
After
derived = [16, 256, 16, 1, 0]
Conditions: none
Maintain acc*base^remaining congruent to the original half-power:accumulate an odd bit,square the base,and halve the exponent to0.This is separate from the square-table calculation.
Step identifiers and dependencies
Rule: Euler_repeated_squaring_original_exponent_invariant · Uses: G001, S031
S033 · implies
Before
source roles = [17, [], -1, 16]
After
derived = [-1, Yes, one finite instance is not a general theorem proof]
Conditions: none
p−1 represents−1 modulo p,not integer equality.Compare the two computations for this instance;one finite table is not a general theorem proof.
Step identifiers and dependencies
Rule: Euler_decode_p_minus1_and_instance_only_comparison · Uses: G001, S032