13#include "arcane/aleph/AlephArcane.h"
27, m_param_epsilon(1.0e-10)
28, m_param_max_iteration(1024)
29, m_param_preconditioner_method(
TypesSolver::DIAGONAL)
33, m_param_xo_user(false)
34, m_param_check_real_residue(false)
35, m_param_print_real_residue(false)
36, m_param_debug_info(false)
37, m_param_min_rhs_norm(1.e-20)
38, m_param_convergence_analyse(false)
39, m_param_stop_error_strategy(true)
40, m_param_write_matrix_to_file_error_strategy(false)
41, m_param_write_matrix_name_error_strategy(
"SolveErrorAlephMatrix.dbg")
42, m_param_listing_output(false)
43, m_param_threshold(0.0)
44, m_param_print_cpu_time_resolution(false)
45, m_param_amg_coarsening_method(0)
46, m_param_output_level(0)
48, m_param_amg_solver_iterations(1)
49, m_param_amg_smoother_iterations(1)
50, m_param_amg_smootherOption(
TypesSolver::SymHybGSJ_smoother)
51, m_param_amg_coarseningOption(
TypesSolver::ParallelRugeStuben)
52, m_param_amg_coarseSolverOption(
TypesSolver::CG_coarse_solver)
53, m_param_keep_solver_structure(false)
54, m_param_sequential_solver(false)
61AlephParams(ITraceMng* tm,
63 Integer max_iteration,
64 TypesSolver::ePreconditionerMethod preconditioner_method,
65 TypesSolver::eSolverMethod solver_method,
69 bool check_real_residue,
70 bool print_real_residue,
73 bool convergence_analyse,
74 bool stop_error_strategy,
75 bool write_matrix_to_file_error_strategy,
76 String write_matrix_name_error_strategy,
79 bool print_cpu_time_resolution,
80 Integer amg_coarsening_method,
83 Integer amg_solver_iterations,
84 Integer amg_smoother_iterations,
85 TypesSolver::eAmgSmootherOption amg_smootherOption,
86 TypesSolver::eAmgCoarseningOption amg_coarseningOption,
87 TypesSolver::eAmgCoarseSolverOption amg_coarseSolverOption,
88 bool keep_solver_structure,
89 bool sequential_solver,
90 TypesSolver::eCriteriaStop param_criteria_stop)
92, m_param_epsilon(epsilon)
93, m_param_max_iteration(max_iteration)
94, m_param_preconditioner_method(preconditioner_method)
95, m_param_solver_method(solver_method)
98, m_param_xo_user(xo_user)
99, m_param_check_real_residue(check_real_residue)
100, m_param_print_real_residue(print_real_residue)
101, m_param_debug_info(debug_info)
102, m_param_min_rhs_norm(min_rhs_norm)
103, m_param_convergence_analyse(convergence_analyse)
104, m_param_stop_error_strategy(stop_error_strategy)
105, m_param_write_matrix_to_file_error_strategy(write_matrix_to_file_error_strategy)
106, m_param_write_matrix_name_error_strategy(write_matrix_name_error_strategy)
107, m_param_listing_output(listing_output)
108, m_param_threshold(threshold)
109, m_param_print_cpu_time_resolution(print_cpu_time_resolution)
110, m_param_amg_coarsening_method(amg_coarsening_method)
111, m_param_output_level(output_level)
112, m_param_amg_cycle(amg_cycle)
113, m_param_amg_solver_iterations(amg_solver_iterations)
114, m_param_amg_smoother_iterations(amg_smoother_iterations)
115, m_param_amg_smootherOption(amg_smootherOption)
116, m_param_amg_coarseningOption(amg_coarseningOption)
117, m_param_amg_coarseSolverOption(amg_coarseSolverOption)
118, m_param_keep_solver_structure(keep_solver_structure)
119, m_param_sequential_solver(sequential_solver)
120, m_param_criteria_stop(param_criteria_stop)
132void AlephParams::setEpsilon(
const Real epsilon)
134 m_param_epsilon = epsilon;
136void AlephParams::setMaxIter(
const Integer max_iteration)
138 m_param_max_iteration = max_iteration;
140void AlephParams::setPrecond(
const TypesSolver::ePreconditionerMethod preconditioner_method)
142 m_param_preconditioner_method = preconditioner_method;
144void AlephParams::setMethod(
const TypesSolver::eSolverMethod solver_method)
146 m_param_solver_method = solver_method;
148void AlephParams::setAlpha(
const Real alpha)
150 m_param_alpha = alpha;
152void AlephParams::setGamma(
const Integer gamma)
154 m_param_gamma = gamma;
156void AlephParams::setXoUser(
const bool xo_user)
158 m_param_xo_user = xo_user;
160void AlephParams::setCheckRealResidue(
const bool check_real_residue)
162 m_param_check_real_residue = check_real_residue;
164void AlephParams::setPrintRealResidue(
const bool print_real_residue)
166 m_param_print_real_residue = print_real_residue;
168void AlephParams::setDebugInfo(
const bool debug_info)
170 m_param_debug_info = debug_info;
172void AlephParams::setMinRHSNorm(
const Real min_rhs_norm)
174 m_param_min_rhs_norm = min_rhs_norm;
176void AlephParams::setConvergenceAnalyse(
const bool convergence_analyse)
178 m_param_convergence_analyse = convergence_analyse;
180void AlephParams::setStopErrorStrategy(
const bool stop_error_strategy)
182 m_param_stop_error_strategy = stop_error_strategy;
184void AlephParams::setWriteMatrixToFileErrorStrategy(
const bool write_matrix_to_file_error_strategy)
186 m_param_write_matrix_to_file_error_strategy = write_matrix_to_file_error_strategy;
188void AlephParams::setWriteMatrixNameErrorStrategy(
const String& write_matrix_name_error_strategy)
190 m_param_write_matrix_name_error_strategy = write_matrix_name_error_strategy;
192void AlephParams::setDDMCParameterListingOutput(
const bool listing_output)
194 m_param_listing_output = listing_output;
196void AlephParams::setDDMCParameterAmgDiagonalThreshold(
const Real threshold)
198 m_param_threshold = threshold;
200void AlephParams::setPrintCpuTimeResolution(
const bool print_cpu_time_resolution)
202 m_param_print_cpu_time_resolution = print_cpu_time_resolution;
206setAmgCoarseningMethod(
const TypesSolver::eAmgCoarseningMethod method)
209 case TypesSolver::AMG_COARSENING_AUTO:
210 m_param_amg_coarsening_method = 6;
212 case TypesSolver::AMG_COARSENING_HYPRE_0:
213 m_param_amg_coarsening_method = 0;
215 case TypesSolver::AMG_COARSENING_HYPRE_1:
216 m_param_amg_coarsening_method = 1;
218 case TypesSolver::AMG_COARSENING_HYPRE_3:
219 m_param_amg_coarsening_method = 3;
221 case TypesSolver::AMG_COARSENING_HYPRE_6:
222 m_param_amg_coarsening_method = 6;
224 case TypesSolver::AMG_COARSENING_HYPRE_7:
225 m_param_amg_coarsening_method = 7;
227 case TypesSolver::AMG_COARSENING_HYPRE_8:
228 m_param_amg_coarsening_method = 8;
230 case TypesSolver::AMG_COARSENING_HYPRE_9:
231 m_param_amg_coarsening_method = 9;
233 case TypesSolver::AMG_COARSENING_HYPRE_10:
234 m_param_amg_coarsening_method = 10;
236 case TypesSolver::AMG_COARSENING_HYPRE_11:
237 m_param_amg_coarsening_method = 11;
239 case TypesSolver::AMG_COARSENING_HYPRE_21:
240 m_param_amg_coarsening_method = 21;
242 case TypesSolver::AMG_COARSENING_HYPRE_22:
243 m_param_amg_coarsening_method = 22;
246 throw NotImplementedException(A_FUNCINFO);
249void AlephParams::setOutputLevel(
const Integer output_level)
251 m_param_output_level = output_level;
253void AlephParams::setAmgCycle(
const Integer amg_cycle)
255 m_param_amg_cycle = amg_cycle;
257void AlephParams::setAmgSolverIter(
const Integer amg_solver_iterations)
259 m_param_amg_solver_iterations = amg_solver_iterations;
261void AlephParams::setAmgSmootherIter(
const Integer amg_smoother_iterations)
263 m_param_amg_smoother_iterations = amg_smoother_iterations;
265void AlephParams::setAmgSmootherOption(
const TypesSolver::eAmgSmootherOption amg_smootherOption)
267 m_param_amg_smootherOption = amg_smootherOption;
269void AlephParams::setAmgCoarseningOption(
const TypesSolver::eAmgCoarseningOption amg_coarseningOption)
271 m_param_amg_coarseningOption = amg_coarseningOption;
273void AlephParams::setAmgCoarseSolverOption(
const TypesSolver::eAmgCoarseSolverOption amg_coarseSolverOption)
275 m_param_amg_coarseSolverOption = amg_coarseSolverOption;
277void AlephParams::setKeepSolverStructure(
const bool keep_solver_structure)
279 m_param_keep_solver_structure = keep_solver_structure;
281void AlephParams::setSequentialSolver(
const bool sequential_solver)
283 m_param_sequential_solver = sequential_solver;
285void AlephParams::setCriteriaStop(
const TypesSolver::eCriteriaStop criteria_stop)
287 m_param_criteria_stop = criteria_stop;
291Real AlephParams::epsilon()
const
293 return m_param_epsilon;
295int AlephParams::maxIter()
const
297 return m_param_max_iteration;
299Real AlephParams::alpha()
const
301 return m_param_alpha;
303int AlephParams::gamma()
const
305 return m_param_gamma;
307TypesSolver::ePreconditionerMethod AlephParams::precond()
309 return m_param_preconditioner_method;
311TypesSolver::eSolverMethod AlephParams::method()
313 return m_param_solver_method;
315bool AlephParams::xoUser()
const
317 return m_param_xo_user;
319bool AlephParams::checkRealResidue()
const
321 return m_param_check_real_residue;
323bool AlephParams::printRealResidue()
const
325 return m_param_print_real_residue;
327bool AlephParams::debugInfo()
329 return m_param_debug_info;
331Real AlephParams::minRHSNorm()
333 return m_param_min_rhs_norm;
335bool AlephParams::convergenceAnalyse()
337 return m_param_convergence_analyse;
339bool AlephParams::stopErrorStrategy()
341 return m_param_stop_error_strategy;
343bool AlephParams::writeMatrixToFileErrorStrategy()
345 return m_param_write_matrix_to_file_error_strategy;
347String AlephParams::writeMatrixNameErrorStrategy()
349 return m_param_write_matrix_name_error_strategy;
351bool AlephParams::DDMCParameterListingOutput()
const
353 return m_param_listing_output;
355Real AlephParams::DDMCParameterAmgDiagonalThreshold()
const
357 return m_param_threshold;
359bool AlephParams::printCpuTimeResolution()
const
361 return m_param_print_cpu_time_resolution;
363int AlephParams::amgCoarseningMethod()
const
365 return m_param_amg_coarsening_method;
367int AlephParams::getOutputLevel()
const
369 return m_param_output_level;
371int AlephParams::getAmgCycle()
const
373 return m_param_amg_cycle;
375int AlephParams::getAmgSolverIter()
const
377 return m_param_amg_solver_iterations;
379int AlephParams::getAmgSmootherIter()
const
381 return m_param_amg_smoother_iterations;
383TypesSolver::eAmgSmootherOption AlephParams::getAmgSmootherOption()
const
385 return m_param_amg_smootherOption;
387TypesSolver::eAmgCoarseningOption AlephParams::getAmgCoarseningOption()
const
389 return m_param_amg_coarseningOption;
391TypesSolver::eAmgCoarseSolverOption AlephParams::getAmgCoarseSolverOption()
const
393 return m_param_amg_coarseSolverOption;
395bool AlephParams::getKeepSolverStructure()
const
397 return m_param_keep_solver_structure;
399bool AlephParams::getSequentialSolver()
const
401 return m_param_sequential_solver;
403TypesSolver::eCriteriaStop AlephParams::getCriteriaStop()
const
405 return m_param_criteria_stop;
-- tab-width: 2; indent-tabs-mode: nil; coding: utf-8-with-signature --