Class documentation of Concepts

Loading...
Searching...
No Matches
fill.hh
1/*----------------------------------------------------------------------------
2Sparse QR solver for linear systems of equations or least squares problems
3Copyright (C) 1996, Thomas H. Robey
4
5This library is free software; you can redistribute it and/or
6modify it under the terms of the GNU Library General Public
7License as published by the Free Software Foundation; either
8version 2 of the License, or (at your option) any later version.
9
10This library is distributed in the hope that it will be useful,
11but WITHOUT ANY WARRANTY; without even the implied warranty of
12MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13Library General Public License for more details.
14
15You should have received a copy of the GNU Library General Public
16License along with this library; if not, write to the Free
17Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
18
19Inquiries can be directed to trobey@arc.unm.edu or
20
21Thomas H. Robey
22925 Madison NE
23Albuquerque, NM 87110
24USA
25----------------------------------------------------------------------------*/
26
27#ifndef fill_hh
28#define fill_hh
29
30#include <cstddef>
31
32namespace sparseqr {
33
38 class Fill {
39 public:
40 int CalcFill(Smatrix *,Smatrix *);
41 Fill(Smatrix *,int);
42 ~Fill();
43 void IndexSort(QR *,int *,int);
44 void Init(QR *,int);
45 void Merge(QR *qr);
46 void PivotFill(QR *qr) {
47 for (int i=0;i<nlist2;i++)
48 pairfill[sortindex2[i]]=CalcFill(qr->srow[row1[sortindex2[i]]],
49 qr->srow[row2[sortindex2[i]]]);
50 };
51 void Update(int,int);
52 int friend QR::sparseqr();
53 private:
54 int nlist1,nlist2;
55 int *sortindex1,*sortindex2,*row1,*row2,*pairfill,*rindex;
56 };
57
58}
59
60#endif // fill_hh