Explore related knowledge and questions →

Question 372: Keep Signed Bezout Coefficients and Verify the Integer Identity

On this page
  1. Original question and givens
  2. Definition and scope
  3. Step-by-step derivation
  4. Reverse checks
  5. Result
  6. This question review and source binding

Return to catalogue page 2

← Question derivation index · Original question batch

P1000-0372 · q-20261014-advance-20261103-r07-modular-inverse-0047

Original question and givens

Use the original signed integer a=5 and modulus n=48≥2. Exact extended Euclid gives nonnegative g=gcd(a,n) and signed coefficients x,y satisfying a*x+n*y=g. An inverse exists exactly when g=1; normalize its representative to 0≤inverse<n. Uniqueness means one residue class modulo n, not a unique integer representative. This family excludes moduli 0 and 1 and does not use approximate division. Give (a,n,gcd,x,y,bezout_value,classification), retaining the coefficients returned by exact Euclidean steps on |a| and n, with the sign of a restored in x.

  • G001 — Use the original signed integer a=5 and modulus n=48≥2. Exact extended Euclid gives nonnegative g=gcd(a,n) and signed coefficients x,y satisfying a*x+n*y=g. An inverse exists exactly when g=1; normalize its representative to 0≤inverse<n. Uniqueness means one residue class modulo n, not a unique integer representative. This family excludes moduli 0 and 1 and does not use approximate division. Give (a,n,gcd,x,y,bezout_value,classification), retaining the coefficients returned by exact Euclidean steps on |a| and n, with the sign of a restored in x.

Definition and scope

Run extended Euclid on |a| and n and restore the sign of a. The coefficients are one Bezout witness, not a unique pair.

Step-by-step derivation

S001 · implies

Before

a=5; n=48≥2

After

compute gcd and a Bezout certificate before inversion

Conditions: none

Invertibility requires coprimality, after qualifying the modulus.

Step identifiers and dependencies

Rule: modular_domain · Uses: G001

S002 · implies

Before

divide 5 by 48

After

5=0·48+5

Conditions: none

Continue with divisor and remainder; nonzero remainders decrease strictly.

Step identifiers and dependencies

Rule: euclidean_division · Uses: G001, S001

S003 · implies

Before

divide 48 by 5

After

48=9·5+3

Conditions: none

Continue with divisor and remainder; nonzero remainders decrease strictly.

Step identifiers and dependencies

Rule: euclidean_division · Uses: G001, S002

S004 · implies

Before

divide 5 by 3

After

5=1·3+2

Conditions: none

Continue with divisor and remainder; nonzero remainders decrease strictly.

Step identifiers and dependencies

Rule: euclidean_division · Uses: G001, S003

S005 · implies

Before

divide 3 by 2

After

3=1·2+1

Conditions: none

Continue with divisor and remainder; nonzero remainders decrease strictly.

Step identifiers and dependencies

Rule: euclidean_division · Uses: G001, S004

S006 · implies

Before

divide 2 by 1

After

2=2·1+0

Conditions: none

Continue with divisor and remainder; nonzero remainders decrease strictly.

Step identifiers and dependencies

Rule: euclidean_division · Uses: G001, S005

S007 · calculation

Before

a·x := mul(5, -19)

After

a·x = -95

Conditions: none

Multiply by the original signed a.

Step identifiers and dependencies

Rule: exact_rational_arithmetic · Uses: G001, S006

S008 · calculation

Before

n·y := mul(48, 2)

After

n·y = 96

Conditions: none

Retain the modulus coefficient as well.

Step identifiers and dependencies

Rule: exact_rational_arithmetic · Uses: G001, S007

S009 · calculation

Before

Bezout value := sum(-95, 96)

After

Bezout value = 1

Conditions: none

The two terms must sum to the final nonzero remainder, the gcd.

Step identifiers and dependencies

Rule: exact_rational_arithmetic · Uses: G001, S008

S010 · implies

Before

5·(-19)+48·(2)=1

After

inverse representative=29; 5·29≡1 (mod 48)

Conditions: none

Modulo n the modulus term vanishes; normalize the coefficient of a into[0,n).

Step identifiers and dependencies

Rule: reduce_bezout · Uses: G001, S009

Reverse checks

  • S010 · premise_and_result_audit — Check integer identities, remainder bounds and gcd conditions; congruence is not integer equality.
  • S009 · premise_and_result_audit — Recompute Bezout value with exact rational arithmetic, not rounded decimals.
  • S008 · premise_and_result_audit — Recompute n·y with exact rational arithmetic, not rounded decimals.
  • S007 · premise_and_result_audit — Recompute a·x with exact rational arithmetic, not rounded decimals.
  • S006 · premise_and_result_audit — Check integer identities, remainder bounds and gcd conditions; congruence is not integer equality.
  • S005 · premise_and_result_audit — Check integer identities, remainder bounds and gcd conditions; congruence is not integer equality.
  • S004 · premise_and_result_audit — Check integer identities, remainder bounds and gcd conditions; congruence is not integer equality.
  • S003 · premise_and_result_audit — Check integer identities, remainder bounds and gcd conditions; congruence is not integer equality.
  • S002 · premise_and_result_audit — Check integer identities, remainder bounds and gcd conditions; congruence is not integer equality.
  • S001 · premise_and_result_audit — Check integer identities, remainder bounds and gcd conditions; congruence is not integer equality.

Result

(5, 48, 1, -19, 2, 1, Bezout_equals_one)

The full substitutions and premise audits recover the original answer, retaining its field order and verdict meanings.

This question review and source binding

Review date: 2026-10-26

Original questions, answers, step expressions, numeric ASTs and historical records are retained. Source candidate labels remain historical and are not overwritten as formal proof.

Source hashes and review receipts
  • input commit: 0f7be61e2c22317a4075561dc822c87d881a50db
  • original question SHA-256: 652e15acd0b2838b561efc3794dfed7d6a92466ba078849d88f1b7e59770535a
  • candidate record SHA-256: 35ebf1737321f2ed425c9e1f3c649ea1280b3a9fc0e4179deaaf685d45be05d6
  • semantic review receipt SHA-256: 6c2c6d46aded7582a11ac41a8c0b3bdde2669a53bdb6e796eea2039994a02772
  • question-first witness SHA-256: 77e43898df9efdbf8094ad81fe4ab91cf4b4bd82f481eb9b4699b73cb4da612b
  • Lean: NOT_RUN · human review: NOT_PERFORMED
Same-source full JSON