The Mathematical Brilliance
of Hazrat Ali (RA)
Three classic accounts of the Gate of Knowledge — solved not with heavy calculation, but with a clear way of seeing the problem. Read each in under a minute; the workings are shown.
Who & why
Ali ibn Abi Talib (RA) — cousin and son-in-law of the Prophet ﷺ — was famed for a sharp, structured mind. The Prophet ﷺ said, "I am the city of knowledge and Ali is its gate." These three problems are well-known traditional accounts passed down to illustrate his wisdom; treat them as teaching stories rather than authenticated hadith. Each makes the same point: frame the problem the right way and the answer becomes simple.
The Perfect Number
Find one whole number divisible by every number from 1 to 10. The answer — 2520 — comes from thinking in real-world structures, not abstract math.
The 17 Camels
A will splits 17 camels by 1/2, 1/3 and 1/9 — impossible without cutting one. Borrow 1, divide cleanly, then give it back.
Bread & Dirhams
8 dirhams for shared bread. Not 4–4, not 5–3, but 1 and 7 — pay by true contribution, not by appearances.
The Number That Amazed the Scholar
A scholar challenged him: "Give me a whole number that, divided by any number from 1 to 10, still gives a whole number — no fractions."
💡 The wisdom
How to Divide 17 Camels Without Harming One
A man's will: eldest son ½, second son ⅓, youngest son ⅑. Total camels: 17. None of these divide cleanly into 17 — so do you cut a camel?
💡 The wisdom
How 3 Loaves Became 1 Dirham & 5 Became 7
Two travellers share bread — one has 5 loaves, the other 3. A third joins. They cut every loaf into 3 equal pieces and all eat equally. The guest leaves 8 dirhams in thanks. How is it split?
not 5–3
💡 The wisdom
"Frame the problem the right way, and the answer is already half-solved."
These are widely-circulated traditional accounts of Imam Ali's wisdom, collected here for study. References: