The number 22871 (twenty-two thousand eight hundred seventy-one) is written in Roman numerals as follows: XXIIDCCCLXXI