annotate liboctave/numeric/eigs-base.h @ 21213:f7d1050b9b53

maint: Clean up various usages of #ifdef. * randmtzig.c: Use #ifdef rather than just #if. * EditControl.h : Use '#if ! defined' rather than '#ifndef' in guard block to match Octave style. * dialog.cc, settings-dialog.cc: Add FIXME notes about questionable use of #if mechanism. * file-editor-tab.cc, Array-b.cc, Array-ch.cc, Array-d.cc, Array-f.cc, Array-i.cc, Array-s.cc, MatrixType.h, quit.h, lo-sysdep.cc, lo-cutils.c, oct-alloc.h, oct-shlib.cc, sparse-sort.h: #define HAVE_XXX macros to 1, not just empty but defined. * octave-txt-lexer.h, octave-cmd.h, octave-preserve-stream-state.h, txt-eng.h, zfstream.h, oct-conf-features.h, oct-conf.h: Use octave_ namespace prefix on name of #define used to prevent multiple inclusion of headers. * parser.h, webinfo.h, ov-oncleanup.h, op-int.h, display-available.h, shared-fcns.h: Add #define guard to prevent multiple inclusion. * quadcc.cc: use all capitals for #define MIN_CQUAD_HEAPSIZE. * ov-intx.h: Add note that this file must not use guard #define. * eigs-base.h, randmtzig.h: Write '! defined' rather than '!defined'. * file-ops.cc, oct-sparse.h: Use parentheses around complex #if tests. * oct-syscalls.cc, oct-base64.cc, statdefs.h: Indent #ifdef blocks correctly. * oct-conf-post.in.h: Use "! defined". Define macros to 1, not just empty but defined.
author Rik <rik@octave.org>
date Sat, 06 Feb 2016 18:22:32 -0800
parents 342764537e5a
children 1473547f50f5
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
21190
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
1 /*
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
2
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
3 Copyright (C) 2005-2015 David Bateman
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
4
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
5 This file is part of Octave.
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
6
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
7 Octave is free software; you can redistribute it and/or modify it
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
8 under the terms of the GNU General Public License as published by the
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
9 Free Software Foundation; either version 3 of the License, or (at your
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
10 option) any later version.
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
11
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
12 Octave is distributed in the hope that it will be useful, but WITHOUT
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
15 for more details.
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
16
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
17 You should have received a copy of the GNU General Public License
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
18 along with Octave; see the file COPYING. If not, see
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
19 <http://www.gnu.org/licenses/>.
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
20
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
21 */
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
22
21213
f7d1050b9b53 maint: Clean up various usages of #ifdef.
Rik <rik@octave.org>
parents: 21190
diff changeset
23 #if ! defined (octave_eigs_base_h)
21190
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
24 #define octave_eigs_base_h 1
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
25
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
26 #include <iosfwd>
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
27
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
28 class ColumnVector;
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
29 class ComplexColumnVector;
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
30 class Matrix;
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
31 class ComplexMatrix;
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
32
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
33 typedef ColumnVector (*EigsFunc) (const ColumnVector& x, int& eigs_error);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
34
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
35 typedef ComplexColumnVector (*EigsComplexFunc) (const ComplexColumnVector& x, int& eigs_error);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
36
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
37 template <typename M>
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
38 octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
39 EigsRealSymmetricMatrix (const M& m, const std::string typ,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
40 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
41 octave_idx_type& info, Matrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
42 ColumnVector& eig_val, const M& _b,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
43 ColumnVector& permB, ColumnVector& resid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
44 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
45 bool cholB, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
46
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
47 template <typename M>
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
48 octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
49 EigsRealSymmetricMatrixShift (const M& m, double sigma,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
50 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
51 octave_idx_type& info, Matrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
52 ColumnVector& eig_val, const M& _b,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
53 ColumnVector& permB, ColumnVector& resid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
54 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
55 bool cholB, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
56
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
57 extern OCTAVE_API octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
58 EigsRealSymmetricFunc (EigsFunc fun, octave_idx_type n,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
59 const std::string& _typ, double sigma,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
60 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
61 octave_idx_type& info, Matrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
62 ColumnVector& eig_val, ColumnVector& resid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
63 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
64 bool /* cholB */, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
65
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
66 template <typename M>
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
67 octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
68 EigsRealNonSymmetricMatrix (const M& m, const std::string typ,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
69 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
70 octave_idx_type& info, ComplexMatrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
71 ComplexColumnVector& eig_val, const M& _b,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
72 ColumnVector& permB, ColumnVector& resid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
73 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
74 bool cholB, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
75
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
76 template <typename M>
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
77 octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
78 EigsRealNonSymmetricMatrixShift (const M& m, double sigmar,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
79 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
80 octave_idx_type& info,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
81 ComplexMatrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
82 ComplexColumnVector& eig_val, const M& _b,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
83 ColumnVector& permB, ColumnVector& resid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
84 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
85 bool cholB, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
86
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
87 extern OCTAVE_API octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
88 EigsRealNonSymmetricFunc (EigsFunc fun, octave_idx_type n,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
89 const std::string& _typ, double sigmar,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
90 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
91 octave_idx_type& info, ComplexMatrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
92 ComplexColumnVector& eig_val, ColumnVector& resid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
93 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
94 bool /* cholB */, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
95
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
96 template <typename M>
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
97 octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
98 EigsComplexNonSymmetricMatrix (const M& m, const std::string typ,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
99 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
100 octave_idx_type& info, ComplexMatrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
101 ComplexColumnVector& eig_val, const M& _b,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
102 ColumnVector& permB,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
103 ComplexColumnVector& cresid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
104 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
105 bool cholB, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
106
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
107 template <typename M>
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
108 octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
109 EigsComplexNonSymmetricMatrixShift (const M& m, Complex sigma,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
110 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
111 octave_idx_type& info,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
112 ComplexMatrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
113 ComplexColumnVector& eig_val, const M& _b,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
114 ColumnVector& permB,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
115 ComplexColumnVector& cresid,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
116 std::ostream& os, double tol, bool rvec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
117 bool cholB, int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
118
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
119 extern OCTAVE_API octave_idx_type
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
120 EigsComplexNonSymmetricFunc (EigsComplexFunc fun, octave_idx_type n,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
121 const std::string& _typ, Complex sigma,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
122 octave_idx_type k, octave_idx_type p,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
123 octave_idx_type& info, ComplexMatrix& eig_vec,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
124 ComplexColumnVector& eig_val,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
125 ComplexColumnVector& cresid, std::ostream& os,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
126 double tol, bool rvec, bool /* cholB */,
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
127 int disp, int maxit);
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
128
342764537e5a don't install eigs-base.cc
John W. Eaton <jwe@octave.org>
parents:
diff changeset
129 #endif