]> gitweb.michael.orlitzky.com - mjotex.git/blob - mjo-linear_algebra.tex
a534523765ef1fd20f7729af25836bb2075fcd3e
[mjotex.git] / mjo-linear_algebra.tex
1 %
2 % Standard operations from linear algebra.
3 %
4 \ifx\havemjolinearalgebra\undefined
5 \def\havemjolinearalgebra{1}
6
7
8 \ifx\lvert\undefined
9 \usepackage{amsmath} % \lvert, \rVert, etc. and \operatorname.
10 \fi
11
12 \ifx\ocircle\undefined
13 \usepackage{wasysym}
14 \fi
15
16 \ifx\clipbox\undefined
17 % Part of the adjustbox package; needed to clip the \perp sign.
18 \usepackage{trimclip}
19 \fi
20
21 \input{mjo-common} % for \of, at least
22
23 % Absolute value (modulus) of a scalar.
24 \newcommand*{\abs}[1]{\left\lvert{#1}\right\rvert}
25
26 % Norm of a vector.
27 \newcommand*{\norm}[1]{\left\lVert{#1}\right\rVert}
28
29 % The inner product between its two arguments.
30 \newcommand*{\ip}[2]{\left\langle{#1},{#2}\right\rangle}
31
32 % The tensor product of its two arguments.
33 \newcommand*{\tp}[2]{ {#1}\otimes{#2} }
34
35 % The Kronecker product of its two arguments. The usual notation for
36 % this is the same as the tensor product notation used for \tp, but
37 % that leads to confusion because the two definitions may not agree.
38 \newcommand*{\kp}[2]{ {#1}\odot{#2} }
39
40 % The adjoint of a linear operator.
41 \newcommand*{\adjoint}[1]{ #1^{*} }
42
43 % The ``transpose'' of a linear operator; namely, the adjoint, but
44 % specialized to real matrices.
45 \newcommand*{\transpose}[1]{ #1^{T} }
46
47 % The Moore-Penrose (or any other, I guess) pseudo-inverse of its
48 % sole argument.
49 \newcommand*{\pseudoinverse}[1]{ #1^{+} }
50
51 % The trace of an operator.
52 \newcommand*{\trace}[1]{ \operatorname{trace}\of{{#1}} }
53
54 % The diagonal matrix whose only nonzero entries are on the diagonal
55 % and are given by our argument. The argument should therefore be a
56 % vector or tuple of entries, by convention going from the top-left to
57 % the bottom-right of the matrix.
58 \newcommand*{\diag}[1]{\operatorname{diag}\of{{#1}}}
59
60 % The "rank" of its argument, which is context-dependent. It can mean
61 % any or all of,
62 %
63 % * the rank of a matrix,
64 % * the rank of a power-associative algebra (particularly an EJA),
65 % * the rank of an element in a Euclidean Jordan algebra.
66 %
67 \newcommand*{\rank}[1]{ \operatorname{rank}\of{{#1}} }
68
69
70 % The ``span of'' operator. The name \span is already taken.
71 \newcommand*{\spanof}[1]{ \operatorname{span}\of{{#1}} }
72
73 % The ``co-dimension of'' operator.
74 \newcommand*{\codim}{ \operatorname{codim} }
75
76 % The orthogonal projection of its second argument onto the first.
77 \newcommand*{\proj}[2] { \operatorname{proj}\of{#1, #2} }
78
79 % The set of all eigenvalues of its argument, which should be either a
80 % matrix or a linear operator. The sigma notation was chosen instead
81 % of lambda so that lambda can be reserved to denote the ordered tuple
82 % (largest to smallest) of eigenvalues.
83 \newcommand*{\spectrum}[1]{\sigma\of{{#1}}}
84 \ifdefined\newglossaryentry
85 \newglossaryentry{spectrum}{
86 name={\ensuremath{\spectrum{L}}},
87 description={the set of all eigenvalues of $L$},
88 sort=s
89 }
90 \fi
91
92 % The ``Automorphism group of'' operator.
93 \newcommand*{\Aut}[1]{ \operatorname{Aut}\of{{#1}} }
94
95 % The ``Lie algebra of'' operator.
96 \newcommand*{\Lie}[1]{ \operatorname{Lie}\of{{#1}} }
97
98 % The ``write a matrix as a big vector'' operator.
99 \newcommand*{\vectorize}[1]{ \operatorname{vec}\of{{#1}} }
100
101 % The ``write a big vector as a matrix'' operator.
102 \newcommand*{\matricize}[1]{ \operatorname{mat}\of{{#1}} }
103
104 % An inline column vector, with parentheses and a transpose operator.
105 \newcommand*{\colvec}[1]{ \transpose{\left({#1}\right)} }
106
107 % Bounded linear operators on some space. The required argument is the
108 % domain of those operators, and the optional argument is the
109 % codomain. If the optional argument is omitted, the required argument
110 % is used for both.
111 \newcommand*{\boundedops}[2][]{
112 \mathcal{B}\of{ {#2}
113 \if\relax\detokenize{#1}\relax
114 {}%
115 \else
116 {,{#1}}%
117 \fi
118 }
119 }
120
121
122 %
123 % Orthogonal direct sum.
124 %
125 % First declare my ``perp in a circle'' operator, which is meant to be
126 % like an \obot or an \operp except has the correct weight circle. It's
127 % achieved by overlaying an \ocircle with a \perp, but only after we
128 % clip off the top half of the \perp sign and shift it up.
129 \DeclareMathOperator{\oplusperp}{\mathbin{
130 \ooalign{
131 $\ocircle$\cr
132 \raisebox{0.625\height}{$\clipbox{0pt 0pt 0pt 0.5\height}{$\perp$}$}\cr
133 }
134 }}
135
136 % Now declare an orthogonal direct sum in terms of \oplusperp.
137 \newcommand*{\directsumperp}[2]{ {#1}\oplusperp{#2} }
138
139
140 % The space of real symmetric n-by-n matrices. Does not reduce to
141 % merely "S" when n=1 since S^{n} does not mean an n-fold cartesian
142 % product of S^{1}.
143 \newcommand*{\Sn}[1][n]{ \mathcal{S}^{#1} }
144 \ifdefined\newglossaryentry
145 \newglossaryentry{Sn}{
146 name={\ensuremath{\Sn}},
147 description={the set of $n$-by-$n$ real symmetric matrices},
148 sort=Sn
149 }
150 \fi
151
152 % The space of complex Hermitian n-by-n matrices. Does not reduce to
153 % merely "H" when n=1 since H^{n} does not mean an n-fold cartesian
154 % product of H^{1}. The field may also be given rather than assumed
155 % to be complex; for example \Hn[3]\of{\mathbb{O}} might denote the
156 % 3-by-3 Hermitian matrices with octonion entries.
157 \newcommand*{\Hn}[1][n]{ \mathcal{H}^{#1} }
158 \ifdefined\newglossaryentry
159 \newglossaryentry{Hn}{
160 name={\ensuremath{\Hn}},
161 description={the set of $n$-by-$n$ complex Hermitian matrices},
162 sort=Hn
163 }
164 \fi
165
166
167 \fi