generated from typst-community/typst-package-template
-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.typ
421 lines (375 loc) · 17.8 KB
/
main.typ
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
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
#import "lib.typ": conf, theorem, definition, lemma, thmrules, proof, pseudocode-list, algorithm
#let ANONYMOUS = false
// IMPORTANT: Reproduction of the `\anon{anonymous}{known}` command
// 1. To ensure anonymity during the double-blind review,
// 2. To easily switch to a non-anonymous version for publication.
//
// With the anon function, first argument shows when anonymous and the second when non-anonymous (known).
// e.g. #anon("Me, Scott Mitchell, wrote this paper.","The author will remain anonymous during the double blind review.")
// e.g. Our code is available at #anon("http://github.com/myname/mycode", "anonymized for double blind review.")
//
// The author and acknowledgements section have already been wrapped in this macro for your convenience.
#let anon(anonymous,known) = {
if ANONYMOUS {
anonymous
}
else {
known
}
}
#show: doc => conf(
title: [#anon("Anonymized","Known-authors") SIAM/ACM Preprint for Use With Typst#footnote([The full version of the paper can be accessed at #anon([`redacted-url`],link("https://arxiv.org/abs/1902.09310"))])],
authors: anon(
"Submission ID XYZ",
(
(
name: "Corey Gray",
affiliation: "Society for Industrial and Applied Mathematics."
),
(
name: "Tricia Manning",
affiliation: "Society for Industrial and Applied Mathematics."
)
)
),
abstract: "An abstract is a brief summary of the paper’s contributions, written for experts. " + anon("Authors are anonymized for double-blind review.","It was written by Gray and Manning."),
doc,
)
= Introduction
An introduction is a gentler description and summary
of the paper than the abstract, written for non-experts.
It describes the paper’s concepts, contribution, context
and significance.
== Problem Specification.
In this paper, we consider the solution of the $N times N$ linear system
// numbered equation
$
A x = B
$ <eq:axb>
where $A$ is large, sparse, symmetric, and positive definite.
We consider the direct solution of @eq:axb by
means of general sparse Gaussian elimination. In such
a procedure, we find a permutation matrix $P$, and compute
the decomposition
// not-numbered equation
#align(center)[
$P A P^t = L D L^t$
]
where $L$ is unit lower triangular and $D$ is diagonal.
= Design Considerations. <sec:design>
Several good ordering algorithms (nested dissection and
minimum degree)
are available for computing $P$~@bib:GEORGELIU @bib:ROSE72.
Since our interest here does not
focus directly on the ordering, we assume for convenience that $P=I$,
or that $A$ has been preordered to reflect an appropriate choice of $P$.
#h(1.5em)
Our purpose here is to examine the nonnumerical complexity of the
sparse elimination algorithm given in~@bib:BANKSMITH.
As was shown there, a general sparse elimination scheme based on the
bordering algorithm requires less storage for pointers and
row/column indices than more traditional implementations of general
sparse elimination. This is accomplished by exploiting the m-tree,
a particular spanning tree for the graph of the filled-in matrix.
#theorem[
The method was extended to three dimensions.
For the standard multigrid coarsening (in
which, for a given grid, the next coarser grid has $1 slash 8$ as
many points), anisotropic problems require plane relaxation
to obtain a good smoothing factor.
] <thm:extend3d>
#h(1.5em)
Our purpose here is to examine the nonnumerical complexity of the
sparse elimination algorithm given in~@bib:BANKSMITH.
As was shown there, a general sparse elimination scheme based on the
bordering algorithm requires less storage for pointers and
row/column indices than more traditional implementations of general
sparse elimination; see @thm:extend3d.
This is accomplished by exploiting the m-tree,
a particular spanning tree for the graph of the filled-in matrix.
Several good ordering algorithms (nested dissection and minimum degree)
are available for computing $P$~@bib:GEORGELIU @bib:ROSE72.
Since our interest here does not
focus directly on the ordering, we assume for convenience that $P=I$,
or that $A$ has been preordered to reflect an appropriate choice of $P$.
#proof[
In this paper we consider two methods. The first method
is basically the method considered with two differences:
first, we perform plane relaxation by a two-dimensional
multigrid method, and second, we use a slightly different
choice of
interpolation operator, which improves performance
for nearly singular problems. In the second method coarsening
is done by successively coarsening in each of the three
independent variables and then ignoring the intermediate
grids; this artifice simplifies coding considerably.
]
#h(1.5em)
Our purpose here is to examine the nonnumerical complexity of the
sparse elimination algorithm given in~@bib:BANKSMITH.
As was shown there, a general sparse elimination scheme based on the
bordering algorithm requires less storage for pointers and
row/column indices than more traditional implementations of general
sparse elimination. This is accomplished by exploiting the m-tree,
a particular spanning tree for the graph of the filled-in matrix.
#definition[
We describe the two methods in @sec:design.
In @sec:robustness we discuss some remaining details.
]
#h(1.5em)
Our purpose here is to examine the nonnumerical complexity of the
sparse elimination algorithm given in @bib:BANKSMITH.
As was shown there, a general sparse elimination scheme based on the
bordering algorithm requires less storage for pointers and
row/column indices than more traditional implementations of general
sparse elimination. This is accomplished by exploiting the m-tree,
a particular spanning tree for the graph of the filled-in matrix.
Several good ordering algorithms (nested dissection and minimum degree)
are available for computing $P$~@bib:GEORGELIU @bib:ROSE72.
Since our interest here does not
focus directly on the ordering, we assume for convenience that $P=I$,
or that $A$ has been preordered to reflect an appropriate choice of $P$.
#h(1.5em)
Our purpose here is to examine the nonnumerical complexity of the
sparse elimination algorithm given in~@bib:BANKSMITH.
As was shown there, a general sparse elimination scheme based on the
bordering algorithm requires less storage for pointers and
row/column indices than more traditional implementations of general
sparse elimination.
#lemma[
We discuss first the choice for $I_(k-1)^k$
which is a generalization. We assume that $G^(k-1)$ is
obtained
from $G^k$
by standard coarsening; that is, if $G^k$ is a tensor product
grid $G_x^k times G_y^k times G_z^k$,
$G^(k-1)=G_x^(k-1) times G_y^(k-1) times G_z^(k-1)$,
where $G_x^(k-1)$ is obtained by deleting every other grid
point of $G_x^k$ and similarly for $G_y^k$ and $G_z^k$.
]
#h(1.5em)
To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
In @sec:robustness, we analyze the complexity of the old and new
approaches to the intersection problem for the special case of
an $n times n$ grid ordered by nested dissection. The special
structure of this problem allows us to make exact estimates of
the complexity. To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
#h(1.5em)
In @sec:design, we review the bordering algorithm, and introduce
the sorting and intersection problems that arise in the
sparse formulation of the algorithm.
In @sec:robustness, we analyze the complexity of the old and new
approaches to the intersection problem for the special case of
an $n times n$ grid ordered by nested dissection. The special
structure of this problem allows us to make exact estimates of
the complexity. To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
#h(1.5em)
For the old approach, we show that the
complexity of the intersection problem is $O(n^3)$, the same
as the complexity of the numerical computations. For the
new approach, the complexity of the second part is reduced to
$O(n^2 (log n)^2)$.
#h(1.5em)
To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
In @sec:robustness, we analyze the complexity of the old and new
approaches to the intersection problem for the special case of
an $n times n$ grid ordered by nested dissection. The special
structure of this problem allows us to make exact estimates of
the complexity. To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
This is accomplished by exploiting the m-tree,
a particular spanning tree for the graph of the filled-in matrix.
To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:EISENSTAT @bib:GEORGELIU @bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE76 @bib:SCHREIBER.
#place(
top,
float: true
)[
#block(width: 100%)[
#figure(
v(14*12pt), // <=> 14pc, with 1pc=12pt
caption: [
This is a blank figure.
]
) <fig:blank>
]
]
#h(1.5em)
We show a blank figure in @fig:blank.
== Robustness. <sec:robustness>
We do not
attempt to present an overview
here, but rather attempt to focus on those results that
are relevant to our particular algorithm; see @fig:blank.
This section assumes prior knowledge of the role of graph theory
in sparse Gaussian elimination; surveys of this role are
available in~@bib:ROSE72 @bib:GEORGELIU. More general
discussions of elimination trees are given in~@bib:LAW @bib:LIU @bib:LIU2 @bib:SCHREIBER.
Thus, at the $k$th stage, the bordering algorithm consists of
solving the lower triangular system
$
L_(k-1)v = c
$
and setting
// with Typst we cannot both
// - have a different number for two successive equations
// - align the equal sign of two successive equations https://typst.app/docs/reference/math/#alignment
$
ell &= D^(-1)_(k-1)v ,
$
$
delta &= alpha - ell^t v .
$
= Algorithm <sec:algorithm>
We provide some pseudocode in @alg:deterministicmps.
#algorithm(
pseudocode-list(
numbered-title: [#smallcaps[(Deterministic-MPS)] maximal
Poisson-disk sampling],
stroke: none,
booktabs: false,
indentation: 2em
)[
- *Require:* Rectangular grid $cal(G)$ of whole grid squares
- *Require:* Flag if domain is pediodic: `True` or `False`
- *Ensure:* Maximal Poisson-disk sampling og rectangle
+ *function* #smallcaps[Deterministic-MPS($cal(G)$)]
+ \/\/ Initialize Grid $cal(G)$
+ *for* $g in cal(G)$ *do*
+ $g$.point = $(u,v)$ uniform random in square
+ $g$.time = $A e^(-A w)$, rand $w$, expovariate in area
+ $g$.scooped-square = square polygon $g$
+ *end for*
+ Global pre-pass heuristic
+ \/\/ Find locally-early squares
+ *for* $g in cal(G)$ and $h in "neighbors"(g)$ *do*
+ increment \#antecedents of $g$ or $h$ (later)
+ *end for*
+ *for* $g in cal(G)$ *do*
+ EarlySquares.add($g$ if no antecedents)
+ *end for*
+ \/\/ Accept samples and update
+ *reapeat*
+ $g$ = EarlySquares.pop() #h(1fr) #sym.triangle any order
+ accept $g$.point as Poisson-disk sample
+ *for* $h in "neighbors"(g)$ *do*
+ decrement $h$.antecedents
+ #h(1fr) #sym.triangle since $g$ no longer blocks $h$
+ \/\/ resample candidates in disk($g$.point)
+ *if* $h$.point #sym.in disk($g$.point) *then*
+ $h$.scooped-square #sym.minus= disk($g$.point)
+ *if* $h$.scooped-square is empty *then*
+ $h$.time = #sym.infinity
+ *else*
+ trim chocks of $h$.scooped-square
+ triangulate remaining polygon
+ $U in {"chocks","triangles"}$ by area
+ $h$.point $in U$ uniform by area
+ $h$.time += expovar(A($h$.scooped-square))
+ *end if*
+ *for* $s in "neighbors"(h)$ *do*
+ *if* $h$ is later than $s$, but was earlier *then*
+ increment $h$.antecedents
]
) <alg:deterministicmps>
// manual break
#pseudocode-list(
stroke: none,
booktabs: false,
indentation: 2em,
line-numbering: x => x+37 // manual line number offset
)[ // manual indentation because we do not start at level 0
+ #h(2em*7)decrement $s$.antecedents
+ #h(2em*6)*if* $s$ has no antecedents *then*
+ #h(2em*7)EarlySquares.add($s$)
+ #h(2em*6)*end if* //6
+ #h(2em*5)*end if* // 5
+ #h(2em*4)*end for* // 4
+ #h(2em*3)*end if* // 3
+ #h(2em*3)*if* $h$ has no antecedents *then* // 3
+ #h(2em*4)EarlySquares.add($h$) // 4
+ #h(2em*3)*end if* // 3
+ #h(2em*2)*end for* //2
+ #h(2em*1)*until* EarlySquares == empty //1
+ *end function*
]
= Results <sec:results>
We do not
attempt to present an overview
here, but rather attempt to focus on those results that
are relevant to our particular algorithm, @alg:deterministicmps.
== Versatility. <sec:versatility> The special
structure of this problem allows us to make exact estimates of
the complexity. For the old approach, we show that the
complexity of the intersection problem is $O(n^3)$, the same
as the complexity of the numerical computations~@bib:GEORGELIU @bib:ROSEWHITTEN. For the
new approach, the complexity of the second part is reduced to
$O(n^2 (log n)^2)$.
#h(1.5em)
To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER}.
In @sec:robustness, we analyze the complexity of the old and new
approaches to the intersection problem for the special case of
an $n times n$ grid ordered by nested dissection. The special
structure of this problem allows us to make exact estimates of
the complexity. To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase @bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
#h(1.5em)
In @sec:design, we review the bordering algorithm, and introduce
the sorting and intersection problems that arise in the
sparse formulation of the algorithm.
In @sec:robustness, we analyze the complexity of the old and new
approaches to the intersection problem for the special case of
an $n times n$ grid ordered by nested dissection. The special
structure of this problem allows us to make exact estimates of
the complexity. To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
#h(1.5em)
For the old approach, we show that the
complexity of the intersection problem is $O(n^3)$, the same
as the complexity of the numerical computations. For the
new approach, the complexity of the second part is reduced to
$O(n^2 (log n)^2)$.
#h(1.5em)
To our knowledge, the m-tree previously has not been applied in this
fashion to the numerical factorization, but it has been used,
directly or indirectly, in several optimal order algorithms for
computing the fill-in during the symbolic factorization phase~@bib:LAW @bib:LIU @bib:LIU2 @bib:ROSE72 @bib:ROSE76 @bib:ROSEWHITTEN @bib:SCHREIBER.
In @sec:robustness, we analyze the complexity of the old and new
approaches to the intersection problem for the special case of
an $n times n$ grid ordered by nested dissection. The special
structure of this problem allows us to make exact estimates of
the complexity.
*Acknowledgements*
#anon(
[Redacted for anonymity.], // Leave as-is
[ //Actual acknowledgement goes here.
I thank Thouis Ray Jones for suggesting this problem to me in 2012, and my institution for funding me.\
#text(size: 6pt)[
#h(1.5em)
My institution requires this disclaimer on all my publications, even though it handicaps its employees by preventing the author from making full use of the proceedings page limit. This technical article contains objective information and does not necessarily represent the subjective opinions of my institution. The authors are not authorized to communicate the policy of the institution. That said, my institution does not necessarily represent my views nor speak for me.
]
])
#bibliography("bib.yml", title: "References", style: "siam.csl")