inline
ArrayView<ElementType>::ArrayView()
:
- starting_element ((nullptr)),
+ starting_element (nullptr),
n_elements(0)
{}
inline
bool IndexSet::IntervalAccessor::is_valid() const
{
- return index_set !=nullptr&& range_idx < index_set->n_intervals();
+ return index_set != nullptr && range_idx < index_set->n_intervals();
}
inline
inline
IndexSet::IntervalIterator::IntervalIterator()
- : accessor((nullptr))
+ : accessor(nullptr)
{}
inline
inline
std::size_t memory_consumption (const char *string)
{
- if (string == (nullptr))
+ if (string == nullptr)
{
return 0;
}
/**
* Creates a new object on the heap using @p new if the given
* @p description is a valid format (for example created by calling
- * description() on an existing object), or nullptr otherwise. Ownership
+ * description() on an existing object), or @p nullptr otherwise. Ownership
* of the returned object is transferred to the caller of this function,
* which should be freed using @p delete.
*/
TaskDescriptor<RT>::TaskDescriptor (const std::function<RT ()> &function)
:
function (function),
- task((nullptr)),
+ task(nullptr),
task_is_done (false)
{}
refine_tol(refine_tol),
coarsen_tol(coarsen_tol),
last_same_as_first(false),
- last_stage((nullptr))
+ last_stage(nullptr)
{
initialize(method);
}
template <typename VectorType>
void EmbeddedExplicitRungeKutta<VectorType>::free_memory()
{
- if (last_stage!=(nullptr))
+ if (last_stage!=nullptr)
delete last_stage;
- last_stage = (nullptr);
+ last_stage = nullptr;
}
// Save the last stage if necessary
if (last_same_as_first==true)
{
- if (last_stage==(nullptr))
+ if (last_stage==nullptr)
last_stage = new VectorType(f_stages.back());
else
*last_stage = f_stages.back();
// of the first stage.
if (last_same_as_first==true)
{
- if (last_stage!=(nullptr))
+ if (last_stage!=nullptr)
{
f_stages[0] = *last_stage;
i = 1;
index),
dof_handler(const_cast<DoFHandlerType *>(dof_handler))
{
- Assert (tria ==nullptr|| &dof_handler->get_triangulation() == tria,
+ Assert (tria == nullptr || &dof_handler->get_triangulation() == tria,
ExcMessage ("You can't create a DoF accessor in which the DoFHandler object "
"uses a different triangulation than the one you pass as argument."));
}
* @code
* FE_Enriched<dim> fe_non_enriched(FE_Q<dim>(1),
* FE_Nothing<dim>(1,true),
- * (nullptr));
+ * nullptr);
* @endcode
* and will result in the correct constraints for enriched DoFs attributed to
* support points on the interface between the two regions.
* classes. Again, see
* @ref GlossUserData "the glossary for more information".
*
- * The value of these user indices or pointers is @pnullptrby default. Note
+ * The value of these user indices or pointers is @p nullptr by default. Note
* that the pointers are not inherited to children upon refinement. Still,
* after a remeshing they are available on all cells, where they were set on
* the previous mesh.
void set_user_pointer (void *p) const;
/**
- * Reset the user pointer to a @pnullptrpointer. See
+ * Reset the user pointer to a @p nullptr pointer. See
* @ref GlossUserData
* for more information.
*/
TriaAccessor<0, dim, spacedim>::
TriaAccessor (const TriaAccessor<structdim2,dim2,spacedim2> &)
:
- tria ((nullptr)),
+ tria (nullptr),
global_vertex_index (numbers::invalid_unsigned_int)
{
Assert(false, ExcImpossibleInDim(0));
TriaAccessor<0, dim, spacedim>::
TriaAccessor (const InvalidAccessor<structdim2,dim2,spacedim2> &)
:
- tria ((nullptr)),
+ tria (nullptr),
global_vertex_index (numbers::invalid_unsigned_int)
{
Assert(false, ExcImpossibleInDim(0));
// If no communication pattern is given, create one. Otherwise, use the
// given one.
std::shared_ptr<const Utilities::MPI::Partitioner> comm_pattern;
- if (communication_pattern.get() == (nullptr))
+ if (communication_pattern.get() == nullptr)
{
// Split the IndexSet of V in locally owned elements and ghost indices
// then create the communication pattern
const bool scientific,
const bool across) const
{
- Assert (partitioner.get() !=nullptr, ExcInternalError());
+ Assert (partitioner.get() != nullptr, ExcInternalError());
AssertThrow (out, ExcIO());
std::ios::fmtflags old_flags = out.flags();
unsigned int old_precision = out.precision (precision);
#if DEAL_II_PETSC_VERSION_LT(3, 7, 0)
const PetscErrorCode ierr = PetscOptionsSetValue (name.c_str (), value.c_str ());
#else
- const PetscErrorCode ierr = PetscOptionsSetValue ((nullptr), name.c_str (), value.c_str ());
+ const PetscErrorCode ierr = PetscOptionsSetValue (nullptr, name.c_str (), value.c_str ());
#endif
AssertThrow (ierr == 0, ExcPETScError(ierr));
}
*/
inline PetscErrorCode destroy_matrix (Mat &matrix)
{
- // PETSc will check whether or not matrix is (nullptr).
+ // PETSc will check whether or not matrix is nullptr.
#if DEAL_II_PETSC_VERSION_LT(3, 2, 0)
return MatDestroy (matrix);
#else
*/
inline PetscErrorCode destroy_krylov_solver (KSP &krylov_solver)
{
- // PETSc will check whether or not matrix is (nullptr).
+ // PETSc will check whether or not matrix is nullptr.
#if DEAL_II_PETSC_VERSION_LT(3, 2, 0)
return KSPDestroy (krylov_solver);
#else
std::shared_ptr<DiagonalMatrix<VectorType> > &preconditioner,
VectorType &diagonal_inverse)
{
- if (preconditioner.get() ==nullptr||
+ if (preconditioner.get() == nullptr ||
preconditioner->m() != matrix.m())
{
- if (preconditioner.get() == (nullptr))
+ if (preconditioner.get() == nullptr)
preconditioner.reset(new DiagonalMatrix<VectorType>());
Assert(preconditioner->m() == 0,
inline
ReadWriteVector<Number>::ReadWriteVector ()
:
- val((nullptr))
+ val(nullptr)
{
reinit(0, true);
}
ReadWriteVector<Number>::ReadWriteVector (const ReadWriteVector<Number> &v)
:
Subscriptor(),
- val((nullptr))
+ val(nullptr)
{
this->operator=(v);
}
inline
ReadWriteVector<Number>::ReadWriteVector (const size_type size)
:
- val((nullptr))
+ val(nullptr)
{
reinit (size, false);
}
inline
ReadWriteVector<Number>::ReadWriteVector (const IndexSet &locally_stored_indices)
:
- val((nullptr))
+ val(nullptr)
{
reinit (locally_stored_indices);
}
{
if (new_alloc_size == 0)
{
- if (val != (nullptr))
+ if (val != nullptr)
free(val);
- val = (nullptr);
+ val = nullptr;
thread_loop_partitioner.reset(new parallel::internal::TBBPartitioner());
}
else
{
- if (val != (nullptr))
+ if (val != nullptr)
free(val);
Utilities::System::posix_memalign ((void **)&val, 64, sizeof(Number)*new_alloc_size);
// If no communication pattern is given, create one. Otherwise, use the
// given one.
std::shared_ptr<const Utilities::MPI::Partitioner> comm_pattern;
- if (communication_pattern.get() == (nullptr))
+ if (communication_pattern.get() == nullptr)
{
comm_pattern.reset(new Utilities::MPI::Partitioner(vec.locally_owned_elements(),
get_stored_elements(),
// If no communication pattern is given, create one. Otherwise, use the one
// given.
- if (communication_pattern == (nullptr))
+ if (communication_pattern == nullptr)
{
// The first time import is called, we create a communication pattern.
// Check if the communication pattern already exists and if it can be
{
epetra_comm_pattern =
std::dynamic_pointer_cast<const EpetraWrappers::CommunicationPattern> (comm_pattern);
- if (epetra_comm_pattern == (nullptr))
+ if (epetra_comm_pattern == nullptr)
epetra_comm_pattern = std::make_shared<const EpetraWrappers::CommunicationPattern>(
create_epetra_comm_pattern(source_elements, mpi_comm));
}
const typename PreconditionBlockBase<InverseNumberType>::Inversion inversion
= PreconditionBlockBase<InverseNumberType>::gauss_jordan,
const double threshold = 0.,
- VectorType *temp_ghost_vector = (nullptr));
+ VectorType *temp_ghost_vector = nullptr);
/**
* The mapping from indices to blocks. Each row of this pattern enumerates
const AdditionalData &data)
:
Solver<VectorType>(cn),
- Vx((nullptr)),
- Vr((nullptr)),
- Vrbar((nullptr)),
- Vp((nullptr)),
- Vy((nullptr)),
- Vz((nullptr)),
- Vt((nullptr)),
- Vv((nullptr)),
- Vb((nullptr)),
+ Vx(nullptr),
+ Vr(nullptr),
+ Vrbar(nullptr),
+ Vp(nullptr),
+ Vy(nullptr),
+ Vz(nullptr),
+ Vt(nullptr),
+ Vv(nullptr),
+ Vb(nullptr),
alpha(0.),
beta(0.),
omega(0.),
const AdditionalData &data)
:
Solver<VectorType>(cn,mem),
- Vr((nullptr)),
- Vp((nullptr)),
- Vz((nullptr)),
+ Vr(nullptr),
+ Vp(nullptr),
+ Vz(nullptr),
additional_data(data)
{}
const AdditionalData &data)
:
Solver<VectorType>(cn),
- Vr((nullptr)),
- Vp((nullptr)),
- Vz((nullptr)),
+ Vr(nullptr),
+ Vp(nullptr),
+ Vz(nullptr),
additional_data(data)
{}
const AdditionalData &)
:
Solver<VectorType>(cn),
- Vu0((nullptr)),
- Vu1((nullptr)),
- Vu2((nullptr)),
- Vm0((nullptr)),
- Vm1((nullptr)),
- Vm2((nullptr)),
- Vv((nullptr)),
+ Vu0(nullptr),
+ Vu1(nullptr),
+ Vu2(nullptr),
+ Vm0(nullptr),
+ Vm1(nullptr),
+ Vm2(nullptr),
+ Vv(nullptr),
res2(numbers::signaling_nan<double>())
{}
const AdditionalData &data)
:
Solver<VectorType> (cn,mem),
- Vr((nullptr)),
- Vd((nullptr)),
+ Vr(nullptr),
+ Vd(nullptr),
additional_data(data)
{}
const AdditionalData &data)
:
Solver<VectorType> (cn),
- Vr((nullptr)),
- Vd((nullptr)),
+ Vr(nullptr),
+ Vd(nullptr),
additional_data(data),
res(numbers::signaling_nan<double>())
{}
ConstraintValues<double> &constraint_values,
bool &cell_at_boundary)
{
- Assert (vector_partitioner.get() !=nullptr, ExcInternalError());
+ Assert (vector_partitioner.get() != nullptr, ExcInternalError());
const unsigned int n_mpi_procs = vector_partitioner->n_mpi_processes();
const types::global_dof_index first_owned = vector_partitioner->local_range().first;
const types::global_dof_index last_owned = vector_partitioner->local_range().second;
const internal::MatrixFreeFunctions::TaskInfo &task_info_in,
const bool is_blocked_in)
:
- dummy ((nullptr)),
+ dummy (nullptr),
worker (worker_in),
partition (partition_in),
task_info (task_info_in),
const internal::MatrixFreeFunctions::TaskInfo &task_info_in,
const bool is_blocked_in = false)
:
- dummy ((nullptr)),
+ dummy (nullptr),
function (function_in),
partition (partition_in),
task_info (task_info_in),
const internal::MatrixFreeFunctions::TaskInfo &task_info_in,
const bool is_blocked_in)
:
- dummy ((nullptr)),
+ dummy (nullptr),
worker (worker_in),
partition (partition_in),
task_info (task_info_in),
{
(void) col;
Assert (row == col, ExcNotImplemented());
- Assert (inverse_diagonal_entries.get() !=nullptr&&
+ Assert (inverse_diagonal_entries.get() != nullptr &&
inverse_diagonal_entries->m() > 0, ExcNotInitialized());
return 1.0/(*inverse_diagonal_entries)(row,row);
}
std::size_t
Base<dim,VectorType>::memory_consumption () const
{
- return inverse_diagonal_entries.get() !=nullptr? inverse_diagonal_entries->memory_consumption() : sizeof(*this);
+ return inverse_diagonal_entries.get() != nullptr ?
+ inverse_diagonal_entries->memory_consumption() : sizeof(*this);
}
const std::shared_ptr<DiagonalMatrix<VectorType> > &
Base<dim,VectorType>::get_matrix_diagonal_inverse() const
{
- Assert(inverse_diagonal_entries.get() !=nullptr&&
+ Assert(inverse_diagonal_entries.get() != nullptr &&
inverse_diagonal_entries->m() > 0, ExcNotInitialized());
return inverse_diagonal_entries;
}
MGInterfaceOperator<OperatorType>::MGInterfaceOperator ()
:
Subscriptor(),
- mf_base_operator((nullptr))
+ mf_base_operator(nullptr)
{
}
void
MGInterfaceOperator<OperatorType>::clear ()
{
- mf_base_operator = (nullptr);
+ mf_base_operator = nullptr;
}
inline const FiniteElement<dim, spacedim> &
IntegrationInfo<dim,spacedim>::finite_element() const
{
- Assert (fe_pointer !=nullptr, ExcNotInitialized());
+ Assert (fe_pointer != nullptr, ExcNotInitialized());
return *fe_pointer;
}
info.indices:
info.indices_by_block[i];
- if (constraints !=nullptr)
+ if (constraints != nullptr)
constraints->distribute_local_to_global(info.vector(k).block(i), ldi, *v);
else
v->add(ldi, info.vector(k).block(i));
/* ------------------ Functions for MGCoarseGridApplySmoother -----------*/
template<class VectorType>
MGCoarseGridApplySmoother<VectorType>::MGCoarseGridApplySmoother ()
- : coarse_smooth((nullptr))
+ : coarse_smooth(nullptr)
{
}
template<class VectorType>
MGCoarseGridApplySmoother<VectorType>::MGCoarseGridApplySmoother (const MGSmootherBase<VectorType> &coarse_smooth)
- : coarse_smooth((nullptr))
+ : coarse_smooth(nullptr)
{
initialize(coarse_smooth);
}
Assert (boundary_functions.size() != 0, ExcInternalError());
Assert (dof_to_boundary_mapping.size() == dof.n_dofs(),
ExcInternalError());
- Assert (coefficient ==nullptr ||
+ Assert (coefficient == nullptr ||
coefficient->n_components==1 ||
coefficient->n_components==n_components, ExcComponentMismatch());
Assert (boundary_functions.size() != 0, ExcInternalError());
Assert (dof_to_boundary_mapping.size() == dof.n_dofs(),
ExcInternalError());
- Assert (coefficient ==nullptr ||
+ Assert (coefficient == nullptr ||
coefficient->n_components==1 ||
coefficient->n_components==n_components, ExcComponentMismatch());
return p;
p = Double::create(description);
- if (p !=nullptr )
+ if (p != nullptr )
return p;
p = Selection::create(description);
- if (p !=nullptr )
+ if (p != nullptr )
return p;
p = List::create(description);
- if (p !=nullptr )
+ if (p != nullptr )
return p;
p = MultipleSelection::create(description);
- if (p !=nullptr )
+ if (p != nullptr )
return p;
p = Bool::create(description);
return p;
p = Anything::create(description);
- if (p !=nullptr )
+ if (p != nullptr )
return p;
p = FileName::create(description);
- if (p !=nullptr )
+ if (p != nullptr )
return p;
p = DirectoryName::create(description);
fe_data.enrichment[base_no].size()));
for (unsigned int m=0; m < base_no_mult_local_enriched_dofs[base_no].size(); m++)
{
- Assert (enrichments[base_no-1][m](cell) !=nullptr,
+ Assert (enrichments[base_no-1][m](cell) != nullptr,
ExcMessage("The pointer to the enrichment function is NULL"));
Assert (enrichments[base_no-1][m](cell)->n_components == 1,
{
const parallel::distributed::Triangulation<dim,spacedim> *parallel_tria =
dynamic_cast<const parallel::distributed::Triangulation<dim,spacedim>*>(&dh.get_tria());
- Assert (parallel_tria !=nullptr, ExcNotImplemented());
+ Assert (parallel_tria != nullptr, ExcNotImplemented());
const IndexSet locally_owned_dofs = dh.locally_owned_dofs();
vector.reinit(locally_owned_dofs, parallel_tria->get_communicator());
{
const parallel::distributed::Triangulation<dim,spacedim> *parallel_tria =
dynamic_cast<const parallel::distributed::Triangulation<dim,spacedim>*>(&dh.get_tria());
- Assert (parallel_tria !=nullptr, ExcNotImplemented());
+ Assert (parallel_tria != nullptr, ExcNotImplemented());
const IndexSet locally_owned_dofs = dh.locally_owned_dofs();
vector.reinit(locally_owned_dofs, parallel_tria->get_communicator());
{
const parallel::distributed::Triangulation<dim,spacedim> *parallel_tria =
dynamic_cast<const parallel::distributed::Triangulation<dim,spacedim>*>(&dh.get_tria());
- Assert (parallel_tria !=nullptr, ExcNotImplemented());
+ Assert (parallel_tria != nullptr, ExcNotImplemented());
const IndexSet locally_owned_dofs = dh.locally_owned_dofs();
vector.reinit(locally_owned_dofs, parallel_tria->get_communicator());
{
const parallel::distributed::Triangulation<dim,spacedim> *parallel_tria =
dynamic_cast<const parallel::distributed::Triangulation<dim,spacedim>*>(&dh.get_tria());
- Assert(parallel_tria !=nullptr, ExcNotImplemented());
+ Assert(parallel_tria != nullptr, ExcNotImplemented());
const IndexSet locally_owned_dofs = dh.locally_owned_dofs();
IndexSet locally_relevant_dofs;
DoFTools::extract_locally_relevant_dofs (dh, locally_relevant_dofs);
{
const parallel::distributed::Triangulation<dim,spacedim> *parallel_tria =
dynamic_cast<const parallel::distributed::Triangulation<dim,spacedim>*>(&dh.get_tria());
- Assert (parallel_tria !=nullptr, ExcNotImplemented());
+ Assert (parallel_tria != nullptr, ExcNotImplemented());
const IndexSet locally_owned_dofs = dh.locally_owned_dofs();
IndexSet locally_relevant_dofs;
DoFTools::extract_locally_relevant_dofs (dh, locally_relevant_dofs);
{
const parallel::distributed::Triangulation<dim,spacedim> *parallel_tria =
dynamic_cast<const parallel::distributed::Triangulation<dim,spacedim>*>(&dh.get_tria());
- Assert (parallel_tria !=nullptr, ExcNotImplemented());
+ Assert (parallel_tria != nullptr, ExcNotImplemented());
const IndexSet locally_owned_dofs = dh.locally_owned_dofs();
IndexSet locally_relevant_dofs;
DoFTools::extract_locally_relevant_dofs (dh, locally_relevant_dofs);