dealii::internal::FEValuesImplementation::FiniteElementRelatedData<1, 2>
&output_data) const
{
- // convert data object to internal
- // data for this class. fails with
- // an exception if that is not
- // possible
- Assert(dynamic_cast<const InternalData *>(&fe_internal) != nullptr,
- ExcInternalError());
- const InternalData &fe_data = static_cast<const InternalData &>(fe_internal);
+ // convert data object to internal data for this class. fails with an
+ // exception if that is not possible
+ const InternalData &fe_data = dynamic_cast<const InternalData &>(fe_internal);
// transform gradients and higher derivatives. there is nothing to do
// for values since we already emplaced them into output_data when
dealii::internal::FEValuesImplementation::FiniteElementRelatedData<2, 3>
&output_data) const
{
- // assert that the following dynamics
- // cast is really well-defined.
- Assert(dynamic_cast<const InternalData *>(&fe_internal) != nullptr,
- ExcInternalError());
- const InternalData &fe_data = static_cast<const InternalData &>(fe_internal);
+ // convert data object to internal data for this class. fails with an
+ // exception if that is not possible
+ const InternalData &fe_data = dynamic_cast<const InternalData &>(fe_internal);
// transform gradients and higher derivatives. there is nothing to do
// for values since we already emplaced them into output_data when
dealii::internal::FEValuesImplementation::FiniteElementRelatedData<1, 2>
&output_data) const
{
- // convert data object to internal
- // data for this class. fails with
- // an exception if that is not
- // possible
-
- Assert(dynamic_cast<const InternalData *>(&fe_internal) != nullptr,
- ExcInternalError());
- const InternalData &fe_data = static_cast<const InternalData &>(fe_internal);
+ // convert data object to internal data for this class. fails with an
+ // exception if that is not possible
+ const InternalData &fe_data = dynamic_cast<const InternalData &>(fe_internal);
// transform gradients and higher derivatives. there is nothing to do
// for values since we already emplaced them into output_data when
dealii::internal::FEValuesImplementation::FiniteElementRelatedData<2, 3>
&output_data) const
{
- Assert(dynamic_cast<const InternalData *>(&fe_internal) != nullptr,
- ExcInternalError());
- const InternalData &fe_data = static_cast<const InternalData &>(fe_internal);
+ // convert data object to internal data for this class. fails with an
+ // exception if that is not possible
+ const InternalData &fe_data = dynamic_cast<const InternalData &>(fe_internal);
// transform gradients and higher derivatives. there is nothing to do
// for values since we already emplaced them into output_data when
{
double factor = 1.;
for (unsigned int i = 1; i <= j; ++i)
- factor *= ((double)(k - i + 1)) / ((double)i);
+ factor *=
+ (static_cast<double>(k - i + 1)) / (static_cast<double>(i));
// factor == k * (k-1) * ... * (k-j+1) / j! = k! / (k-j)! / j!
if (c == 0)
{
int factorial_i = 1;
- for (int i = 2; i < (int)this->dofs_per_face; ++i)
+ for (unsigned int i = 2; i < this->dofs_per_face; ++i)
{
interpolation_matrix(i, i) = std::pow(0.5, i);
factorial_i *= i;
int factorial_j = factorial_i;
int factorial_ij = 1;
- for (int j = i + 1; j < (int)this->dofs_per_face; ++j)
+ for (unsigned int j = i + 1; j < this->dofs_per_face; ++j)
{
factorial_ij *= j - i;
factorial_j *= j;
int factorial_i = 1;
- for (int i = 2; i < (int)this->dofs_per_face; ++i)
+ for (unsigned int i = 2; i < this->dofs_per_face; ++i)
{
interpolation_matrix(i, i) = std::pow(0.5, i);
factorial_i *= i;
int factorial_j = factorial_i;
int factorial_ij = 1;
- for (int j = i + 1; j < (int)this->dofs_per_face; ++j)
+ for (unsigned int j = i + 1; j < this->dofs_per_face; ++j)
{
factorial_ij *= j - i;
factorial_j *= j;
int factorial_i = 1;
- for (int i = 2; i <= (int)this->degree; ++i)
+ for (unsigned int i = 2; i <= this->degree; ++i)
{
double tmp = std::pow(0.5, i);
interpolation_matrix(i + 2, i + 2) = tmp;
int factorial_k = 1;
- for (int j = 2; j <= (int)this->degree; ++j)
+ for (unsigned int j = 2; j <= this->degree; ++j)
{
interpolation_matrix(i + (j + 2) * source_fe.degree -
j,
int factorial_kl = 1;
int factorial_l = factorial_k;
- for (int k = j + 1; k < (int)this->degree; ++k)
+ for (unsigned int k = j + 1; k < this->degree; ++k)
{
factorial_kl *= k - j;
factorial_l *= k;
int factorial_j = factorial_i;
int factorial_ij = 1;
- for (int j = i + 1; j <= (int)this->degree; ++j)
+ for (unsigned int j = i + 1; j <= this->degree; ++j)
{
factorial_ij *= j - i;
factorial_j *= j;
j + 2 * this->degree) = tmp;
factorial_k = 1;
- for (int k = 2; k <= (int)this->degree; ++k)
+ for (unsigned int k = 2; k <= this->degree; ++k)
{
interpolation_matrix(
i + (k + 2) * source_fe.degree - k,
int factorial_l = factorial_k;
int factorial_kl = 1;
- for (int l = k + 1; l <= (int)this->degree;
+ for (unsigned int l = k + 1;
+ l <= this->degree;
++l)
{
factorial_kl *= l - k;
j + 2 * this->degree) = tmp;
factorial_k = 1;
- for (int k = 2; k <= (int)this->degree; ++k)
+ for (unsigned int k = 2; k <= this->degree; ++k)
{
interpolation_matrix(
i + (k + 2) * source_fe.degree - k,
int factorial_l = factorial_k;
int factorial_kl = 1;
- for (int l = k + 1; l <= (int)this->degree;
+ for (unsigned int l = k + 1;
+ l <= this->degree;
++l)
{
factorial_kl *= l - k;
int factorial_i = 1;
- for (int i = 2; i <= (int)this->degree; ++i)
+ for (unsigned int i = 2; i <= this->degree; ++i)
{
double tmp = std::pow(0.5, i + 1);
interpolation_matrix(i + 2, i + 2) = tmp;
int factorial_j = factorial_i;
int factorial_ij = 1;
- for (int j = i + 1; j <= (int)this->degree; ++j)
+ for (unsigned int j = i + 1; j <= this->degree; ++j)
{
factorial_ij *= j - i;
factorial_j *= j;
j + 2 * this->degree) = tmp;
int factorial_k = 1;
- for (int k = 2; k <= (int)this->degree; ++k)
+ for (unsigned int k = 2; k <= this->degree; ++k)
{
interpolation_matrix(
i + (k + 2) * source_fe.degree - k,
int factorial_l = factorial_k;
int factorial_kl = 1;
- for (int l = k + 1; l <= (int)this->degree; ++l)
+ for (unsigned int l = k + 1; l <= this->degree;
+ ++l)
{
factorial_kl *= l - k;
factorial_l *= l;
int factorial_k = 1;
- for (int j = 2; j <= (int)this->degree; ++j)
+ for (unsigned int j = 2; j <= this->degree; ++j)
{
interpolation_matrix(i + (j + 2) * source_fe.degree -
j,
int factorial_l = factorial_k;
int factorial_kl = 1;
- for (int k = j + 1; k <= (int)this->degree; ++k)
+ for (unsigned int k = j + 1; k <= this->degree; ++k)
{
factorial_kl *= k - j;
factorial_l *= k;
int factorial_i = 1;
- for (int i = 2; i <= (int)this->degree; ++i)
+ for (unsigned int i = 2; i <= this->degree; ++i)
{
double tmp = std::pow(0.5, i);
interpolation_matrix(i + 2, i + 2) = tmp;
int factorial_k = 1;
- for (int j = 2; j <= (int)this->degree; ++j)
+ for (unsigned int j = 2; j <= this->degree; ++j)
{
interpolation_matrix(i + (j + 2) * source_fe.degree -
j,
int factorial_kl = 1;
int factorial_l = factorial_k;
- for (int k = j + 1; k <= (int)this->degree; ++k)
+ for (unsigned int k = j + 1; k <= this->degree; ++k)
{
factorial_kl *= k - j;
factorial_l *= k;
int factorial_j = factorial_i;
int factorial_ij = 1;
- for (int j = i + 1; j <= (int)this->degree; ++j)
+ for (unsigned int j = i + 1; j <= this->degree; ++j)
{
factorial_ij *= j - i;
factorial_j *= j;
j + 3 * this->degree - 1) = tmp;
int factorial_k = 1;
- for (int k = 2; k <= (int)this->degree; ++k)
+ for (unsigned int k = 2; k <= this->degree; ++k)
{
interpolation_matrix(
i + (k + 2) * source_fe.degree - k,
int factorial_l = factorial_k;
int factorial_kl = 1;
- for (int l = k + 1; l <= (int)this->degree; ++l)
+ for (unsigned int l = k + 1; l <= this->degree;
+ ++l)
{
factorial_kl *= l - k;
factorial_l *= l;
int factorial_i = 1;
- for (int i = 2; i <= (int)this->degree; ++i)
+ for (unsigned int i = 2; i <= this->degree; ++i)
{
double tmp = std::pow(0.5, i + 1);
interpolation_matrix(i + 2, i + 2) = tmp;
i + 3 * this->degree - 1) = tmp;
int factorial_k = 1;
- for (int j = 2; j <= (int)this->degree; ++j)
+ for (unsigned int j = 2; j <= this->degree; ++j)
{
interpolation_matrix(i + (j + 2) * source_fe.degree -
j,
int factorial_l = factorial_k;
int factorial_kl = 1;
- for (int k = j + 1; k <= (int)this->degree; ++k)
+ for (unsigned int k = j + 1; k <= this->degree; ++k)
{
factorial_kl *= k - j;
factorial_l *= k;
int factorial_j = factorial_i;
int factorial_ij = 1;
- for (int j = i + 1; j <= (int)this->degree; ++j)
+ for (unsigned int j = i + 1; j <= this->degree; ++j)
{
factorial_ij *= j - i;
factorial_j *= j;
j + 3 * this->degree - 1) = tmp;
int factorial_k = 1;
- for (int k = 2; k <= (int)this->degree; ++k)
+ for (unsigned int k = 2; k <= this->degree; ++k)
{
interpolation_matrix(
i + (k + 2) * source_fe.degree - k,
int factorial_l = factorial_k;
int factorial_kl = 1;
- for (int l = k + 1; l <= (int)this->degree; ++l)
+ for (unsigned int l = k + 1; l <= this->degree;
+ ++l)
{
factorial_kl *= l - k;
factorial_l *= l;