The number 31087 (thirty-one thousand eighty-seven) is written in Roman numerals as follows: XXXILXXXVII