Beginner

Diamond Problem Calculator — Solve the Number Diamond Puzzle

The diamond problem gives you a product (top) and a sum (bottom) — find the two numbers that belong in the left and right cells. This tool solves it algebraically in one click and shows every step.
The number in the top of the diamond — the product of the two unknowns
The number in the bottom of the diamond — the sum of the two unknowns
First number (a)
4

The larger of the two numbers in the left and right cells

Second number (b)
3
Check: a × b
12
Check: a + b
7
Discriminant (S² − 4P)
1
Step-by-step solution
1

Set up the quadratic: x² − (sum)·x + (product) = 0

x² − 7x + 12 = 0
2

Calculate the discriminant: Δ = sum² − 4 × product

Δ = 7² − 4 × 12 = 1
3

Apply the quadratic formula: x = (sum ± √Δ) / 2

x = (7 ± √1) / 2
=

Two solutions

a = 4, b = 3
Step by step
  1. 1

    Discriminant Δ = S² − 4P

    7² − 4 × 12 = 1
    If Δ < 0 there are no real solutions.
  2. 2

    Square root of discriminant

    √1 = 1
  3. 3

    First number a = (S + √Δ) ÷ 2

    (7 + 1) ÷ 2 = 4
Results are estimates for general information only and are not professional advice — always verify important results independently before relying on them. Read the full disclaimer.
Quick answer

How does this calculator work?

Given the top (product P) and bottom (sum S) of a diamond puzzle, the two side numbers are found by solving x² − S·x + P = 0: a, b = (S ± √(S² − 4P)) / 2. Enter product and sum above to get both values and a full step-by-step solution instantly.

Formula
x² − (sum)·x + (product) = 0 → a, b = (sum ± √(sum² − 4·product)) / 2
How this is calculated

A diamond problem arranges four numbers in a diamond shape: the top cell holds the product of two unknown numbers, the bottom cell holds their sum, and the left and right cells are the unknowns themselves. Given top (P) and bottom (S), the task is to find a and b such that a × b = P and a + b = S.

This is identical to solving the quadratic equation x² − S·x + P = 0. The quadratic formula gives x = (S ± √(S² − 4P)) / 2. The two roots of this equation are exactly the two numbers that belong in the diamond. If the discriminant S² − 4P is negative there are no real solutions — you would need to check that the values entered are consistent.

Diamond problems are widely used in middle-school and high-school algebra to build intuition for factoring quadratics of the form x² + bx + c, because the two numbers you find become the roots of the factored form (x − a)(x − b). Working the diamond problem first makes it easier to see the structure of the full trinomial.

Frequently asked questions

A diamond problem is a visual puzzle with four cells arranged in a diamond. The top cell holds the product of two mystery numbers; the bottom holds their sum. You must find the two numbers that satisfy both at once — the same task as factoring a quadratic trinomial.

If the discriminant (sum² − 4 × product) is negative, there are no real numbers that simultaneously have that product and that sum. In classroom settings this usually means a typo in the problem — real diamond problems are designed so the discriminant is non-negative.

When factoring x² + bx + c, you need two numbers that multiply to c and add to b — exactly the diamond problem with product = c and sum = b. The two solutions are the constants in the factored form (x + a)(x + b).

Also known as

diamond problem solver
find two numbers with given product and sum
diamond math puzzle
factoring diamond method
product sum puzzle
quadratic factoring helper
diamond problem algebra

APA

TG we-Calculate Editorial Team. (2026). Diamond Problem Calculator — Solve the Number Diamond Puzzle [Online calculator]. TG we-Calculate. https://we-calculate.com/calculator/diamond-problem-calculator

Chicago

TG we-Calculate Editorial Team. "Diamond Problem Calculator — Solve the Number Diamond Puzzle." TG we-Calculate. 2026. https://we-calculate.com/calculator/diamond-problem-calculator.

IEEE

TG we-Calculate Editorial Team, "Diamond Problem Calculator — Solve the Number Diamond Puzzle," TG we-Calculate, 2026. [Online]. Available: https://we-calculate.com/calculator/diamond-problem-calculator

BibTeX

@misc{wecalculate_diamond_problem_calculator, title = {Diamond Problem Calculator — Solve the Number Diamond Puzzle}, author = {{TG we-Calculate Editorial Team}}, howpublished = {\url{https://we-calculate.com/calculator/diamond-problem-calculator}}, year = {2026}, note = {TG we-Calculate} }

Did this calculator help you?