system_matrix.compress(VectorOperation::add);
system_rhs.compress(VectorOperation::add);
- std::map<types::global_dof_index, double> boundary_values;
- VectorTools::interpolate_boundary_values(mapping,
- dof_handler,
- 0,
- Functions::ZeroFunction<dim>(dim),
- boundary_values);
+ std::map<types::global_dof_index, PetscScalar> boundary_values;
+ VectorTools::interpolate_boundary_values(
+ mapping,
+ dof_handler,
+ 0,
+ Functions::ZeroFunction<dim, PetscScalar>(dim),
+ boundary_values);
MatrixTools::apply_boundary_values(
boundary_values, system_matrix, solution, system_rhs, false);
}
#endif
- FEValuesExtractors::Scalar z_component(dim - 1);
- std::map<types::global_dof_index, double> boundary_values;
- VectorTools::interpolate_boundary_values(mapping,
- dof_handler,
- 0,
- Functions::ZeroFunction<dim>(dim),
- boundary_values);
+ FEValuesExtractors::Scalar z_component(dim - 1);
+ std::map<types::global_dof_index, PetscScalar> boundary_values;
+ VectorTools::interpolate_boundary_values(
+ mapping,
+ dof_handler,
+ 0,
+ Functions::ZeroFunction<dim, PetscScalar>(dim),
+ boundary_values);
VectorTools::interpolate_boundary_values(
mapping,
dof_handler,
system_rhs,
preconditioner),
solver_control.last_step(),
- 5,
+ 1,
9);
constraints.distribute(completely_distributed_solution);
void
LaplaceProblem<dim>::run()
{
- deallog << "Running with "
-#ifdef USE_PETSC_LA
- << "PETSc"
-#else
- << "Trilinos"
-#endif
+ deallog << "Running "
<< " on " << Utilities::MPI::n_mpi_processes(mpi_communicator)
<< " MPI rank(s)..." << std::endl;
-DEAL::Running with PETSc on 1 MPI rank(s)...
+DEAL::Running on 1 MPI rank(s)...
DEAL:: Number of active cells: 512
DEAL:: Number of degrees of freedom: 1089
-DEAL::Solver stopped within 5 - 9 iterations
+DEAL::Solver stopped within 1 - 9 iterations
DEAL::0.0124965
-DEAL::Running with PETSc on 4 MPI rank(s)...
+DEAL::Running on 4 MPI rank(s)...
DEAL:: Number of active cells: 512
DEAL:: Number of degrees of freedom: 1089
-DEAL::Solver stopped within 5 - 9 iterations
+DEAL::Solver stopped within 1 - 9 iterations
DEAL::0.0124965