aboutsummaryrefslogtreecommitdiff
path: root/src/hyper/pages/ROMAN.ht
blob: 44c58a6431886356f6fe68a967909371fac4e4c2 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
% Copyright The Numerical Algorithms Group Limited 1992-94. All rights reserved.
% !! DO NOT MODIFY THIS FILE BY HAND !! Created by ht.awk.
\newcommand{\RomanNumeralXmpTitle}{RomanNumeral}
\newcommand{\RomanNumeralXmpNumber}{9.68}
%
% =====================================================================
\begin{page}{RomanNumeralXmpPage}{9.68 RomanNumeral}
% =====================================================================
\beginscroll

The Roman numeral package was added to \Language{} in MCMLXXXVI
%-% \HDindex{Roman numerals}{RomanNumeralXmpPage}{9.68}{RomanNumeral}
for use in denoting higher order derivatives.

\xtc{
For example, let \spad{f} be a symbolic operator.
}{
\spadpaste{f := operator 'f \bound{f}}
}
\xtc{
This is the seventh derivative of \spad{f} with respect to \spad{x}.
}{
\spadpaste{D(f x,x,7) \free{f}}
}
\xtc{
You can have integers printed as Roman numerals by declaring variables to
be of type \spadtype{RomanNumeral} (abbreviation \spadtype{ROMAN}).
}{
\spadpaste{a := roman(1978 - 1965) \bound{a}}
}

This package now has a small but devoted group of followers that claim
this domain has shown its efficacy in many other contexts.
They claim that Roman numerals are every bit as useful as ordinary
integers.
\xtc{
In a sense, they are correct, because Roman numerals form a ring and you
can therefore construct polynomials with Roman numeral coefficients,
matrices over Roman numerals, etc..
}{
\spadpaste{x : UTS(ROMAN,'x,0) := x \bound{x}}
}
\xtc{
Was Fibonacci Italian or ROMAN?
%-% \HDindex{Fibonacci numbers}{RomanNumeralXmpPage}{9.68}{RomanNumeral}
}{
\spadpaste{recip(1 - x - x**2) \free{x}}
}
\xtc{
You can also construct fractions with Roman numeral numerators and
denominators, as this matrix Hilberticus illustrates.
}{
\spadpaste{m : MATRIX FRAC ROMAN \bound{m}}
}
\xtc{
}{
\spadpaste{m := matrix [[1/(i + j) for i in 1..3] for j in 1..3] \free{m} \bound{m1}}
}
\xtc{
Note that the inverse of the matrix has integral \spadtype{ROMAN} entries.
}{
\spadpaste{inverse m \free{m1}}
}
\xtc{
Unfortunately, the spoil-sports say that the fun stops when
the numbers get big---mostly
because the Romans didn't establish conventions about representing
very large numbers.
}{
\spadpaste{y := factorial 10 \bound{y}}
}
\xtc{
You work it out!
}{
\spadpaste{roman y \free{y}}
}
Issue the system command
\spadcmd{)show RomanNumeral}
to display the full list of operations defined by
\spadtype{RomanNumeral}.
\endscroll
\autobuttons
\end{page}
%