Package org.hipparchus.util
Class RomanNumeral
java.lang.Object
org.hipparchus.util.RomanNumeral
Utility class to manage roman numerals.
- Since:
- 4.1
-
Method Summary
-
Method Details
-
toRoman
Convert an integer to roman numeral.The classical subtractive form is generated here, i.e. 4 is represented as IV and not IIII.
- Parameters:
n- number to convert- Returns:
- string representation as a roman numeral
-
parse
Convert roman numeral to an integer.We accept here the additive form (IIII instead of IV).
- Parameters:
r- roman numeral to convert- Returns:
- value of the roman numeral
-