The number 840031 (eight hundred forty thousand thirty-one) is written in Roman numerals as follows: DCCCXLXXXI