Unix and Linux Discussions Tagged with math |
|
Thread / Thread Starter |
Last Post |
Replies |
Views |
Forum |
|
|
|
1 |
9,314 |
Shell Programming and Scripting |
|
|
|
6 |
2,296 |
UNIX for Beginners Questions & Answers |
|
|
|
1 |
1,540 |
Shell Programming and Scripting |
|
|
|
5 |
2,038 |
Shell Programming and Scripting |
|
|
|
3 |
3,686 |
UNIX for Dummies Questions & Answers |
|
|
|
3 |
9,100 |
UNIX for Dummies Questions & Answers |
|
|
|
5 |
82,851 |
UNIX for Dummies Questions & Answers |
|
|
|
4 |
12,779 |
UNIX for Dummies Questions & Answers |
|
|
|
7 |
4,229 |
UNIX for Dummies Questions & Answers |
|
|
|
10 |
4,487 |
Shell Programming and Scripting |
|
|
|
0 |
1,080 |
Software Releases - RSS News |
|
|
|
0 |
1,025 |
Software Releases - RSS News |
|
|
|
0 |
789 |
Software Releases - RSS News |
|
|
|
0 |
957 |
Software Releases - RSS News |
|
|
|
0 |
729 |
Software Releases - RSS News |
|
|
|
2 |
19,969 |
Programming |
|
|
|
7 |
22,873 |
Shell Programming and Scripting |
|
|
|
0 |
1,177 |
Software Releases - RSS News |
|
|
|
0 |
970 |
Software Releases - RSS News |
|
|
|
5 |
3,185 |
Shell Programming and Scripting |
|
|
|
1 |
6,534 |
Solaris |
|
|
|
0 |
945 |
Software Releases - RSS News |
|
|
|
0 |
1,082 |
Software Releases - RSS News |
|
|
|
9 |
4,354 |
Programming |
|
|
|
2 |
15,078 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
48,486 |
Programming |
|
|
|
3 |
4,774 |
UNIX for Dummies Questions & Answers |
|
|
|
5 |
35,603 |
UNIX for Advanced & Expert Users |
|
|
|
3 |
48,406 |
UNIX for Advanced & Expert Users |
|
|
|
4 |
3,141 |
UNIX for Dummies Questions & Answers |
|
|
|
2 |
2,946 |
UNIX for Dummies Questions & Answers |
|
|
|
1 |
2,555 |
UNIX for Dummies Questions & Answers |
math::roman(1.0) math::roman(1.0)
__________________________________________________________________________________________________________________________________________________
NAME
math::roman - Tools for creating and manipulating roman numerals
SYNOPSIS
package require Tcl 8.3
package require math::roman ?1.0?
::math::roman::toroman i
::math::roman::tointeger r
::math::roman::sort list
::math::roman::expr args
_________________________________________________________________
DESCRIPTION
::math::roman is a pure-Tcl library for converting between integers and roman numerals. It also provides utility functions for sorting and
performing arithmetic on roman numerals.
This code was originally harvested from the Tcler's wiki at http://wiki.tcl.tk/1823 and as such is free for any use for any purpose. Many
thanks to the ingeneous folk who devised these clever routines and generously contributed them to the Tcl community.
While written and tested under Tcl 8.3, I expect this library will work under all 8.x versions of Tcl.
COMMANDS
::math::roman::toroman i
Convert an integer to roman numerals. The result is always in upper case. The value zero is converted to an empty string.
::math::roman::tointeger r
Convert a roman numeral into an integer.
::math::roman::sort list
Sort a list of roman numerals from smallest to largest.
::math::roman::expr args
Evaluate an expression where the operands are all roman numerals.
Of these commands both toroman and tointeger are exported for easier use. The other two are not, as they could interfer or be confused with
existing Tcl commands.
BUGS, IDEAS, FEEDBACK
This document, and the package it describes, will undoubtedly contain bugs and other problems. Please report such in the category math ::
roman of the Tcllib SF Trackers [http://sourceforge.net/tracker/?group_id=12883]. Please also report any ideas for enhancements you may
have for either package and/or documentation.
KEYWORDS
conversion, integer, roman numeral
COPYRIGHT
Copyright (c) 2005 Kenneth Green <kenneth.green@gmail.com>
Tcl Math Library math math::roman(1.0)