* as interior (0), the faces decorated with as exterior (1), and the
* cells (2) according to CellOrFaceAccess.
*/
- std::vector<IndexStorageVariants> index_storage_variants[3];
+ std::array<std::vector<IndexStorageVariants>, 3> index_storage_variants;
/**
* Stores the rowstart indices of the compressed row storage in the @p
* as interior (0), the faces decorated with as exterior (1), and the
* cells (2) according to CellOrFaceAccess.
*/
- std::vector<unsigned int> dof_indices_contiguous[3];
+ std::array<std::vector<unsigned int>, 3> dof_indices_contiguous;
/**
* Compressed index storage for faster access than through @p
* as minus (0), the faces decorated with as plus (1), and the cells
* (2).
*/
- std::vector<unsigned int> dof_indices_interleave_strides[3];
+ std::array<std::vector<unsigned int>, 3> dof_indices_interleave_strides;
/**
* Caches the number of indices filled when vectorizing. This
* as interior (0), the faces decorated with as exterior (1), and the
* cells (2) according to CellOrFaceAccess.
*/
- std::vector<unsigned char> n_vectorization_lanes_filled[3];
+ std::array<std::vector<unsigned char>, 3> n_vectorization_lanes_filled;
/**
* This stores the parallel partitioning that can be used to set up
for (unsigned int face = 0; face < faces.size(); ++face)
{
auto face_computation = [&](const DoFAccessIndex face_index,
- const unsigned int * cell_indices_face) {
+ const std::array<unsigned int, length>
+ &cell_indices_face) {
bool is_contiguous = false;
bool is_interleaved = false;
bool needs_full_storage = false;
private:
template <bool do_evaluate, bool add_into_output, int face_direction = 0>
static void
- interpolate_generic(const Number * input,
- Number * output,
- const bool do_gradients,
- const unsigned int face_no,
- const unsigned int n_points_1d,
- const AlignedVector<Number> *shape_data,
- const unsigned int dofs_per_component_on_cell,
- const unsigned int dofs_per_component_on_face)
+ interpolate_generic(const Number * input,
+ Number * output,
+ const bool do_gradients,
+ const unsigned int face_no,
+ const unsigned int n_points_1d,
+ const std::array<AlignedVector<Number>, 2> &shape_data,
+ const unsigned int dofs_per_component_on_cell,
+ const unsigned int dofs_per_component_on_face)
{
if (face_direction == face_no / 2)
{
* numbers of the cells on the logical "interior" side of the face which
* is aligned to the direction of FEEvaluation::get_normal_vector().
*/
- unsigned int cells_interior[vectorization_width];
+ std::array<unsigned int, vectorization_width> cells_interior;
/**
* Indices of the faces in the current face batch as compared to the
* For boundary faces, the numbers are set to
* `numbers::invalid_unsigned_int`.
*/
- unsigned int cells_exterior[vectorization_width];
+ std::array<unsigned int, vectorization_width> cells_exterior;
/**
* Index of the face between 0 and GeometryInfo::faces_per_cell within
* but the default case (cell integrals or boundary integrals) only
* fills the zeroth component and ignores the first one.
*/
- AlignedVector<Tensor<2, spacedim, VectorizedArrayType>> jacobians[2];
+ std::array<AlignedVector<Tensor<2, spacedim, VectorizedArrayType>>, 2>
+ jacobians;
/**
* The storage of the gradients of the inverse Jacobian
* but the default case (cell integrals or boundary integrals) only
* fills the zeroth component and ignores the first one.
*/
- AlignedVector<Tensor<1,
- spacedim *(spacedim + 1) / 2,
- Tensor<1, spacedim, VectorizedArrayType>>>
- jacobian_gradients[2];
+ std::array<
+ AlignedVector<Tensor<1,
+ spacedim *(spacedim + 1) / 2,
+ Tensor<1, spacedim, VectorizedArrayType>>>,
+ 2>
+ jacobian_gradients;
/**
* Stores the Jacobian transformations times the normal vector (this
*
* Indexed by @p data_index_offsets.
*/
- AlignedVector<Tensor<1, spacedim, VectorizedArrayType>>
- normals_times_jacobians[2];
+ std::array<AlignedVector<Tensor<1, spacedim, VectorizedArrayType>>, 2>
+ normals_times_jacobians;
/**
* Stores the index offset of a particular cell into the quadrature
* (the vertices) in one data structure. Sorting is first the values,
* then gradients, then second derivatives.
*/
- AlignedVector<Number> shape_data_on_face[2];
+ std::array<AlignedVector<Number>, 2> shape_data_on_face;
/**
* Collects all data of 1D nodal shape values (defined by the Lagrange
*
* @note In contrast to shape_data_on_face, only the vales are evaluated.
*/
- AlignedVector<Number> quadrature_data_on_face[2];
+ std::array<AlignedVector<Number>, 2> quadrature_data_on_face;
/**
* Stores one-dimensional values of shape functions on subface. Since
* there are two subfaces, store two variants.
*/
- AlignedVector<Number> values_within_subface[2];
+ std::array<AlignedVector<Number>, 2> values_within_subface;
/**
* Stores one-dimensional gradients of shape functions on subface. Since
* there are two subfaces, store two variants.
*/
- AlignedVector<Number> gradients_within_subface[2];
+ std::array<AlignedVector<Number>, 2> gradients_within_subface;
/**
* Stores one-dimensional gradients of shape functions on subface. Since
* there are two subfaces, store two variants.
*/
- AlignedVector<Number> hessians_within_subface[2];
+ std::array<AlignedVector<Number>, 2> hessians_within_subface;
/**
* We store a copy of the one-dimensional quadrature formula