BEM++  2.0
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Groups Pages
aca_options.hpp
1 // Copyright (C) 2011-2012 by the BEM++ Authors
2 //
3 // Permission is hereby granted, free of charge, to any person obtaining a copy
4 // of this software and associated documentation files (the "Software"), to deal
5 // in the Software without restriction, including without limitation the rights
6 // to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
7 // copies of the Software, and to permit persons to whom the Software is
8 // furnished to do so, subject to the following conditions:
9 //
10 // The above copyright notice and this permission notice shall be included in
11 // all copies or substantial portions of the Software.
12 //
13 // THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
14 // IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
15 // FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
16 // AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
17 // LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
18 // OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
19 // THE SOFTWARE.
20 
21 #ifndef bempp_aca_options_hpp
22 #define bempp_aca_options_hpp
23 
24 #include "../common/common.hpp"
25 
26 #include <string>
27 
28 namespace Bempp
29 {
30 
34 struct AcaOptions
35 {
37  AcaOptions();
38 
42  double eps;
43 
47  double eta;
48 
55  unsigned int minimumBlockSize;
56 
64  unsigned int maximumBlockSize;
65 
71  unsigned int maximumRank;
72 
76  MIN_ASSEMBLY_MODE,
77  GLOBAL_ASSEMBLY = MIN_ASSEMBLY_MODE,
78  LOCAL_ASSEMBLY,
79  HYBRID_ASSEMBLY,
80  MAX_ASSEMBLY_MODE = HYBRID_ASSEMBLY
81  };
82 
172 
177  MIN_REACTION,
178  IGNORE = MIN_REACTION,
179  WARNING,
180  ERROR,
181  MAX_REACTION = ERROR
182  };
183 
201 
212 
218 
224  std::string outputFname;
225 
230  double scaling;
231 
247 
257 
264 };
265 
266 } // namespace Bempp
267 
268 #endif
int firstClusterIndex
Index of the first block cluster to be approximated using ACA.
Definition: aca_options.hpp:256
ReactionToUnsupportedMode
Actions to take when an unsupported assembly mode is detected.
Definition: aca_options.hpp:176
bool outputPostscript
If true, hierarchical matrix structure will be written in PostScript format at the end of the assembl...
Definition: aca_options.hpp:217
ReactionToUnsupportedMode reactionToUnsupportedMode
Action to take when an unsupported assembly mode is detected.
Definition: aca_options.hpp:200
double eta
Cluster-pair admissibility parameter.
Definition: aca_options.hpp:47
Adaptive cross approximation (ACA) parameters.
Definition: aca_options.hpp:34
bool recompress
Recompress ACA matrix after construction?
Definition: aca_options.hpp:211
bool useAhmedAca
Choice of ACA variant.
Definition: aca_options.hpp:246
bool globalAssemblyBeforeCompression
Do global assembly before ACA?
Definition: aca_options.hpp:263
AcaOptions()
Initialize ACA parameters to default values.
Definition: aca_options.cpp:27
double scaling
Estimate of the magnitude of typical entries of the matrix to be approximated.
Definition: aca_options.hpp:230
AcaAssemblyMode mode
ACA assembly mode.
Definition: aca_options.hpp:171
std::string outputFname
Name of the output PostScript file.
Definition: aca_options.hpp:224
double eps
Estimate of the desired approximation accuracy.
Definition: aca_options.hpp:42
unsigned int maximumBlockSize
Maximum allowed block size.
Definition: aca_options.hpp:64
unsigned int maximumRank
Maximum rank of blocks stored in the low-rank format.
Definition: aca_options.hpp:71
unsigned int minimumBlockSize
Minimum size of blocks approximated with ACA.
Definition: aca_options.hpp:55
AcaAssemblyMode
ACA assembly mode. See documentation of the member mode for more information.
Definition: aca_options.hpp:75