This page explains how Roman numerals work.
This is the convention I was taught in school. The Romans (and
subsequent users) weren't nearly as strict about how to write
numbers in their day, but this is the way you will see Roman
numerals written in almost all cases today.
The Letters
First, here is the value of each letter:
I = 1 (one)
V = 5 (five)
X = 10 (ten)
L = 50 (fifty)
C = 100 (one hundred)
D = 500 (five hundred)
M = 1000 (one thousand)
Note that there was no number smaller than
one. The concept of zero and negative numbers did not exist.
There are actually values over 1000 (M).
Putting a bar over the appropriate letter indicates it should
be multiplied by 1000. So, for example, "V" with a
bar over it would be 5000. This gives letters up to M-bar or
1,000,000 (one million). Unfortunately, barred letters are hard
to write in HTML, so we'll stick with non-barred letters. (By
the way, "I" was never barred since I-bar equals "M.")
The Rules
The letters should be arranged from the
one with the largest value to the one with the smallest. Each
letter's value is added to the previous ones.
Only powers of ten (I, X, C, M) can be
repeated. Do not repeat any letter more than three times in a
row.
Because of the preceding rule, certain
numbers must be written using subtraction. In this case, a letter
with a smaller value precedes one with a larger value and the
value of the smaller is subtracted from the larger. The result
is then added to the rest of the letters. The following rules
apply to subtraction:
Only powers of ten (I, X, C, M)
can be subtracted.
The smaller letter must be 1/5th (one-fifth)
or 1/10th (one-tenth) the larger one.
The smaller letter must be either the first
letter or preceded by a letter at least ten times greater than
it.
If another letter follows the larger one,
it must be smaller than the number preceding the larger one.
Examples for Each Rule
1510 is written MDX, not XDM or DXM or
other combinations.
100 is not written LL (not a power of ten)
or XXXXXXXXXX (too many repeated Xs).
CCXLIII = 100 + 100 + (50 - 10) + 1 + 1
+ 1 = 243.
800 isn't CCM because you can only subtract
one letter from another, not two.
45 isn't VL because V (5) isn't
a power of ten.
99 isn't IC because I (1) is 1/100th of
C (100), not 1/10th.
49 isn't IL because I (1) is 1/50th of
L (50), not 1/5th.
1400 isn't DCM because D (500) is less
than 1000 (10 * 100 (C)).
140 isn't XCL because L (50) isn't smaller
than X (10).
100 isn't XCX because X (10) isn't smaller
than itself.
In Plain English
Think of each combination of letters of
equal powers of ten as one digit. For example, in CCCLXII (362),
CCC (300) is the hundreds, LX (60) is the tens, and II (2) is
the ones.
Subtraction only takes place for four and
nine times a power of ten (i.e. 4, 40, 400, 9, 90, 900). This
is to avoid more than three of the same letter in a row. It is
written by putting a smaller value in front of a larger one.
So 4 is IV, not IIII. And 900 is CM, not DCCCC.
This complicates the first statement of
this section some because there might be a higher power of ten
in a lower power of tens section. For example, in MCMIX (1909),
M (1000) is the thousands, CM (1000 - 100 = 900) is the hundreds,
and IX (10 - 1 = 9) is the ones.
To put it most concisely: When converting
to Roman numerals, convert each digit separately. For example,
for 953 convert 900, 50, and 3 to give CM, L, and III to get
CMLIII.