135Mathematics · Number bases

Unknown Number Base or Digit

Unknown Number Base or Digit

Find legal integer bases from 2 to 16 or one missing digit in a two- or three-digit positional numeral.

  • 279 bytes
  • COMP mode
01

Worked examples

Example 1

Original exercise. Expand the positional numeral and find every legal base or digit satisfying the equality. (101)_b=10₁₀; 2≤b≤16, b∈ℤ. b=?

Answer
b=3.
Standard solution (without a calculator)
  1. Substitute the conditions, solve the equations, then retain only values satisfying the stated domain.
  2. Equation: b²+1=10 ⇒ b²=9.
  3. Calculation: b≥2 ⇒ b=3.
  4. Conclusion: 1<3; 0<3; 3²+1=10.
Do it on the calculator

Example 2

Original exercise. Expand the positional numeral and find every legal base or digit satisfying the equality. (2x)_b=20₁₀; 2≤b≤16, b∈ℤ; 0≤x<b, x∈ℤ. (b,x)=?

Answer
(b,x)∈{(7,6),(8,4),(9,2),(10,0)}.
Standard solution (without a calculator)
  1. Substitute the conditions, solve the equations, then retain only values satisfying the stated domain.
  2. Equation: 2b+x=20 ⇒ x=20−2b.
  3. Calculation: 0≤20−2b<b ⇒ 20/3<b≤10.
  4. Conclusion: (b,x)=(7,6),(8,4),(9,2),(10,0).
Do it on the calculator

Example 3

Original exercise. Expand the positional numeral and find every legal base or digit satisfying the equality. (10x)₄=16₁₀; 0≤x<4, x∈ℤ. x=?

Answer
x=0.
Standard solution (without a calculator)
  1. Substitute the conditions, solve the equations, then retain only values satisfying the stated domain.
  2. Equation: 16+x=16.
  3. Calculation: x=0; 0≤0<4.
  4. Conclusion: x=0.
Do it on the calculator
02

When to use it

Find legal integer bases from 2 to 16 or one missing digit in a two- or three-digit positional numeral.

Input order

  • X:N → Y:b/0 → A → C → D
  • Enter all fields again for every run. Blank EXE retains old memory; zero must be typed as 0EXE.

Results

  • b → −1
  • 100b+x → 100b+x → 100b+x → 100b+x → −1
  • x → −1
  • All displayed values follow the output order below. A pause requires EXE; the final screen uses AC.

Conditions and limits

  • Enter decimal N, known base (0 if unknown), then the three digits A,C,D in Ab²+Cb+D; for two digits pad A=0. Use −1 for at most one unknown digit. Bases are integers 2…16; each digit is an integer 0…b−1 with no leading zero. Outputs are b if all digits are known, x for a fixed base, or 100b+x when base and digit are unknown. Final −1 marks completion, not a solution. Zero is a valid digit. All seven variables and Ans are overwritten; Fix 0 is temporary and the program ends in Norm 1.
  • The finite precision and numeric range of the calculator limit very large, very small or nearly cancelling values.

Sign in to unlock the full programme

Checking access…

The programme code and appendix unlock together.

Checking access…

Sign in to unlock the full programme

Checking access…

The programme code and appendix unlock together.