int direction, bool dof_to_quad, bool add>
inline
void
- apply_tensor_product (const VectorizedArray<Number> *shape_data,
- const VectorizedArray<Number> in [],
- VectorizedArray<Number> out [])
+ apply_tensor_product (const Number *shape_data,
+ const Number in [],
+ Number out [])
{
AssertIndexRange (direction, dim);
const int mm = dof_to_quad ? (fe_degree+1) : n_q_points_1d,
{
for (int col=0; col<nn; ++col)
{
- VectorizedArray<Number> val0;
+ Number val0;
if (dof_to_quad == true)
val0 = shape_data[col];
else
val0 = shape_data[col*n_q_points_1d];
- VectorizedArray<Number> res0 = val0 * in[0];
+ Number res0 = val0 * in[0];
for (int ind=1; ind<mm; ++ind)
{
if (dof_to_quad == true)
int direction, bool dof_to_quad, bool add>
inline
void
- apply_tensor_product_values (const VectorizedArray<Number> *shape_values,
- const VectorizedArray<Number> in [],
- VectorizedArray<Number> out [])
+ apply_tensor_product_values (const Number *shape_values,
+ const Number in [],
+ Number out [])
{
AssertIndexRange (direction, dim);
const int mm = dof_to_quad ? (fe_degree+1) : n_q_points_1d,
{
for (int col=0; col<n_cols; ++col)
{
- VectorizedArray<Number> val0, val1, in0, in1, res0, res1;
+ Number val0, val1, in0, in1, res0, res1;
if (dof_to_quad == true)
{
val0 = shape_values[col];
}
}
else
- res0 = res1 = VectorizedArray<Number>();
+ res0 = res1 = Number();
if (dof_to_quad == true)
{
if (mm % 2 == 1)
}
else if (dof_to_quad == true && nn%2==1)
{
- VectorizedArray<Number> res0;
- VectorizedArray<Number> val0 = shape_values[n_cols];
+ Number res0;
+ Number val0 = shape_values[n_cols];
if (mid > 0)
{
res0 = in[0] + in[stride*(mm-1)];
for (int ind=1; ind<mid; ++ind)
{
val0 = shape_values[ind*n_q_points_1d+n_cols];
- VectorizedArray<Number> val1 = in[stride*ind] + in[stride*(mm-1-ind)];
+ Number val1 = in[stride*ind] + in[stride*(mm-1-ind)];
val1 *= val0;
res0 += val1;
}
}
else
- res0 = VectorizedArray<Number>();
+ res0 = Number();
if (add == false)
out[stride*n_cols] = res0;
else
}
else if (dof_to_quad == false && nn%2 == 1)
{
- VectorizedArray<Number> res0;
+ Number res0;
if (mid > 0)
{
- VectorizedArray<Number> val0 = shape_values[n_cols*n_q_points_1d];
+ Number val0 = shape_values[n_cols*n_q_points_1d];
res0 = in[0] + in[stride*(mm-1)];
res0 *= val0;
for (int ind=1; ind<mid; ++ind)
{
val0 = shape_values[n_cols*n_q_points_1d+ind];
- VectorizedArray<Number> val1 = in[stride*ind] + in[stride*(mm-1-ind)];
+ Number val1 = in[stride*ind] + in[stride*(mm-1-ind)];
val1 *= val0;
res0 += val1;
}
int direction, bool dof_to_quad, bool add>
inline
void
- apply_tensor_product_gradients (const VectorizedArray<Number> *shape_gradients,
- const VectorizedArray<Number> in [],
- VectorizedArray<Number> out [])
+ apply_tensor_product_gradients (const Number *shape_gradients,
+ const Number in [],
+ Number out [])
{
AssertIndexRange (direction, dim);
const int mm = dof_to_quad ? (fe_degree+1) : n_q_points_1d,
{
for (int col=0; col<n_cols; ++col)
{
- VectorizedArray<Number> val0, val1, in0, in1, res0, res1;
+ Number val0, val1, in0, in1, res0, res1;
if (dof_to_quad == true)
{
val0 = shape_gradients[col];
}
}
else
- res0 = res1 = VectorizedArray<Number>();
+ res0 = res1 = Number();
if (mm % 2 == 1)
{
if (dof_to_quad == true)
}
if ( nn%2 == 1 )
{
- VectorizedArray<Number> val0, res0;
+ Number val0, res0;
if (dof_to_quad == true)
val0 = shape_gradients[n_cols];
else
val0 = shape_gradients[ind*n_q_points_1d+n_cols];
else
val0 = shape_gradients[n_cols*n_q_points_1d+ind];
- VectorizedArray<Number> val1 = in[stride*ind] - in[stride*(mm-1-ind)];
+ Number val1 = in[stride*ind] - in[stride*(mm-1-ind)];
val1 *= val0;
res0 += val1;
}
int direction, bool dof_to_quad, bool add>
inline
void
- apply_tensor_product_hessians (const VectorizedArray<Number> *shape_hessians,
- const VectorizedArray<Number> in [],
- VectorizedArray<Number> out [])
+ apply_tensor_product_hessians (const Number *shape_hessians,
+ const Number in [],
+ Number out [])
{
AssertIndexRange (direction, dim);
const int mm = dof_to_quad ? (fe_degree+1) : n_q_points_1d,
{
for (int col=0; col<n_cols; ++col)
{
- VectorizedArray<Number> val0, val1, in0, in1, res0, res1;
+ Number val0, val1, in0, in1, res0, res1;
if (dof_to_quad == true)
{
val0 = shape_hessians[col];
}
}
else
- res0 = res1 = VectorizedArray<Number>();
+ res0 = res1 = Number();
if (mm % 2 == 1)
{
if (dof_to_quad == true)
}
if ( nn%2 == 1 )
{
- VectorizedArray<Number> val0, res0;
+ Number val0, res0;
if (dof_to_quad == true)
val0 = shape_hessians[n_cols];
else
val0 = shape_hessians[ind*n_q_points_1d+n_cols];
else
val0 = shape_hessians[n_cols*n_q_points_1d+ind];
- VectorizedArray<Number> val1 = in[stride*ind] + in[stride*(mm-1-ind)];
+ Number val1 = in[stride*ind] + in[stride*(mm-1-ind)];
val1 *= val0;
res0 += val1;
}
}
else
- res0 = VectorizedArray<Number>();
+ res0 = Number();
if (mm % 2 == 1)
{
if (dof_to_quad == true)
int direction, bool dof_to_quad, bool add>
inline
void
- apply_tensor_product_gradients_gl (const VectorizedArray<Number> *shape_gradients,
- const VectorizedArray<Number> in [],
- VectorizedArray<Number> out [])
+ apply_tensor_product_gradients_gl (const Number *shape_gradients,
+ const Number in [],
+ Number out [])
{
AssertIndexRange (direction, dim);
const int mm = fe_degree+1;
{
for (int col=0; col<n_cols; ++col)
{
- VectorizedArray<Number> val0, val1, in0, in1, res0, res1;
+ Number val0, val1, in0, in1, res0, res1;
if (mid > 0)
{
if (dof_to_quad == true)
}
}
else
- res0 = res1 = VectorizedArray<Number>();
+ res0 = res1 = Number();
if (mm % 2 == 1)
{
if (dof_to_quad == true)
}
if ( nn%2 == 1 )
{
- VectorizedArray<Number> val0, res0;
+ Number val0, res0;
if (dof_to_quad == true)
val0 = shape_gradients[n_cols];
else
val0 = shape_gradients[ind*mm+n_cols];
else
val0 = shape_gradients[n_cols*mm+ind];
- VectorizedArray<Number> val1 = in[stride*ind] - in[stride*(mm-1-ind)];
+ Number val1 = in[stride*ind] - in[stride*(mm-1-ind)];
val1 *= val0;
res0 += val1;
}
}
else
- res0 = VectorizedArray<Number>();
+ res0 = Number();
if (add == false)
out[stride*n_cols] = res0;
else
::apply_values(const VectorizedArray<Number> in [],
VectorizedArray<Number> out [])
{
- internal::apply_tensor_product<dim,fe_degree,n_q_points_1d,Number,
- direction, dof_to_quad, add>
+ internal::apply_tensor_product<dim,fe_degree,n_q_points_1d,
+ VectorizedArray<Number>, direction, dof_to_quad, add>
(this->data.shape_values.begin(), in, out);
}
::apply_gradients(const VectorizedArray<Number> in [],
VectorizedArray<Number> out [])
{
- internal::apply_tensor_product<dim,fe_degree,n_q_points_1d,Number,
- direction, dof_to_quad, add>
+ internal::apply_tensor_product<dim,fe_degree,n_q_points_1d,
+ VectorizedArray<Number>, direction, dof_to_quad, add>
(this->data.shape_gradients.begin(), in, out);
}
::apply_hessians(const VectorizedArray<Number> in [],
VectorizedArray<Number> out [])
{
- internal::apply_tensor_product<dim,fe_degree,n_q_points_1d,Number,
- direction, dof_to_quad, add>
+ internal::apply_tensor_product<dim,fe_degree,n_q_points_1d,
+ VectorizedArray<Number>, direction, dof_to_quad, add>
(this->data.shape_hessians.begin(), in, out);
}
::apply_values (const VectorizedArray<Number> in [],
VectorizedArray<Number> out [])
{
- internal::apply_tensor_product_values<dim,fe_degree,n_q_points_1d,Number,
- direction, dof_to_quad, add>
+ internal::apply_tensor_product_values<dim,fe_degree,n_q_points_1d,
+ VectorizedArray<Number>, direction, dof_to_quad, add>
(this->data.shape_values.begin(), in, out);
}
::apply_gradients (const VectorizedArray<Number> in [],
VectorizedArray<Number> out [])
{
- internal::apply_tensor_product_gradients<dim,fe_degree,n_q_points_1d,Number,
- direction, dof_to_quad, add>
+ internal::apply_tensor_product_gradients<dim,fe_degree,n_q_points_1d,
+ VectorizedArray<Number>, direction, dof_to_quad, add>
(this->data.shape_gradients.begin(), in, out);
}
::apply_hessians (const VectorizedArray<Number> in [],
VectorizedArray<Number> out [])
{
- internal::apply_tensor_product_hessians<dim,fe_degree,n_q_points_1d,Number,
- direction, dof_to_quad, add>
+ internal::apply_tensor_product_hessians<dim,fe_degree,n_q_points_1d,
+ VectorizedArray<Number>, direction, dof_to_quad, add>
(this->data.shape_hessians.begin(), in, out);
}
::apply_gradients (const VectorizedArray<Number> in [],
VectorizedArray<Number> out [])
{
- internal::apply_tensor_product_gradients_gl<dim,fe_degree,Number,
- direction, dof_to_quad, add>
+ internal::apply_tensor_product_gradients_gl<dim,fe_degree,
+ VectorizedArray<Number>, direction, dof_to_quad, add>
(this->data.shape_gradients.begin(), in, out);
}