MappingCartesian<dim, spacedim>::InternalData::memory_consumption () const
{
return (Mapping<dim, spacedim>::InternalDataBase::memory_consumption() +
- MemoryConsumption::memory_consumption (length) +
+ MemoryConsumption::memory_consumption (cell_extents) +
MemoryConsumption::memory_consumption (volume_element) +
MemoryConsumption::memory_consumption (quadrature_points));
}
switch (dim)
{
case 1:
- data.length[0] = cell->vertex(1)(0) - start(0);
+ data.cell_extents[0] = cell->vertex(1)(0) - start(0);
break;
case 2:
- data.length[0] = cell->vertex(1)(0) - start(0);
- data.length[1] = cell->vertex(2)(1) - start(1);
+ data.cell_extents[0] = cell->vertex(1)(0) - start(0);
+ data.cell_extents[1] = cell->vertex(2)(1) - start(1);
break;
case 3:
- data.length[0] = cell->vertex(1)(0) - start(0);
- data.length[1] = cell->vertex(2)(1) - start(1);
- data.length[2] = cell->vertex(4)(2) - start(2);
+ data.cell_extents[0] = cell->vertex(1)(0) - start(0);
+ data.cell_extents[1] = cell->vertex(2)(1) - start(1);
+ data.cell_extents[2] = cell->vertex(4)(2) - start(2);
break;
default:
Assert(false, ExcNotImplemented());
{
quadrature_points[i] = start;
for (unsigned int d=0; d<dim; ++d)
- quadrature_points[i](d) += data.length[d] *
+ quadrature_points[i](d) += data.cell_extents[d] *
data.quadrature_points[i+offset](d);
}
}
if (data.update_each & (update_JxW_values | update_volume_elements))
if (cell_similarity != CellSimilarity::translation)
{
- double J = data.length[0];
+ double J = data.cell_extents[0];
for (unsigned int d=1; d<dim; ++d)
- J *= data.length[d];
+ J *= data.cell_extents[d];
data.volume_element = J;
if (data.update_each & update_JxW_values)
for (unsigned int i=0; i<output_data.JxW_values.size(); ++i)
{
output_data.jacobians[i] = DerivativeForm<1,dim,spacedim>();
for (unsigned int j=0; j<dim; ++j)
- output_data.jacobians[i][j][j] = data.length[j];
+ output_data.jacobians[i][j][j] = data.cell_extents[j];
}
// "compute" the derivative of the Jacobian
// at the quadrature points, which are all
{
output_data.inverse_jacobians[i]=Tensor<2,dim>();
for (unsigned int j=0; j<dim; ++j)
- output_data.inverse_jacobians[j][j]=1./data.length[j];
+ output_data.inverse_jacobians[j][j]=1./data.cell_extents[j];
}
return cell_similarity;
double J = 1.;
for (unsigned int d=0; d<dim; ++d)
if (d != GeometryInfo<dim>::unit_normal_direction[face_no])
- J *= data.length[d];
+ J *= data.cell_extents[d];
if (data.update_each & update_JxW_values)
for (unsigned int i=0; i<output_data.JxW_values.size(); ++i)
if (data.update_each & update_volume_elements)
{
- J = data.length[0];
+ J = data.cell_extents[0];
for (unsigned int d=1; d<dim; ++d)
- J *= data.length[d];
+ J *= data.cell_extents[d];
data.volume_element = J;
}
{
output_data.jacobians[i] = DerivativeForm<1,dim,spacedim>();
for (unsigned int d=0; d<dim; ++d)
- output_data.jacobians[i][d][d] = data.length[d];
+ output_data.jacobians[i][d][d] = data.cell_extents[d];
}
if (data.update_each & update_inverse_jacobians)
{
output_data.inverse_jacobians[i] = DerivativeForm<1,dim,spacedim>();
for (unsigned int d=0; d<dim; ++d)
- output_data.inverse_jacobians[i][d][d] = 1./data.length[d];
+ output_data.inverse_jacobians[i][d][d] = 1./data.cell_extents[d];
}
}
double J = 1.;
for (unsigned int d=0; d<dim; ++d)
if (d != GeometryInfo<dim>::unit_normal_direction[face_no])
- J *= data.length[d];
+ J *= data.cell_extents[d];
if (data.update_each & update_JxW_values)
{
if (data.update_each & update_volume_elements)
{
- J = data.length[0];
+ J = data.cell_extents[0];
for (unsigned int d=1; d<dim; ++d)
- J *= data.length[d];
+ J *= data.cell_extents[d];
data.volume_element = J;
}
{
output_data.jacobians[i] = DerivativeForm<1,dim,spacedim>();
for (unsigned int d=0; d<dim; ++d)
- output_data.jacobians[i][d][d] = data.length[d];
+ output_data.jacobians[i][d][d] = data.cell_extents[d];
}
if (data.update_each & update_inverse_jacobians)
{
output_data.inverse_jacobians[i] = DerivativeForm<1,spacedim,dim>();
for (unsigned int d=0; d<dim; ++d)
- output_data.inverse_jacobians[i][d][d] = 1./data.length[d];
+ output_data.inverse_jacobians[i][d][d] = 1./data.cell_extents[d];
}
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d=0; d<dim; ++d)
- output[i][d] = input[i][d]/data.length[d];
+ output[i][d] = input[i][d]/data.cell_extents[d];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d=0; d<dim; ++d)
- output[i][d] = input[i][d]*data.length[d];
+ output[i][d] = input[i][d]*data.cell_extents[d];
return;
}
case mapping_piola:
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d=0; d<dim; ++d)
- output[i][d] = input[i][d] * data.length[d] / data.volume_element;
+ output[i][d] = input[i][d] * data.cell_extents[d] / data.volume_element;
return;
}
default:
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] / data.length[d2];
+ output[i][d1][d2] = input[i][d1][d2] / data.cell_extents[d2];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2];
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] / data.length[d2] / data.length[d1];
+ output[i][d1][d2] = input[i][d1][d2] / data.cell_extents[d2] / data.cell_extents[d1];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2] / data.length[d1];
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2] / data.cell_extents[d1];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2]
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2]
/ data.volume_element;
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2]
- / data.length[d1] / data.volume_element;
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2]
+ / data.cell_extents[d1] / data.volume_element;
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] / data.length[d2];
+ output[i][d1][d2] = input[i][d1][d2] / data.cell_extents[d2];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2];
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] / data.length[d2] / data.length[d1];
+ output[i][d1][d2] = input[i][d1][d2] / data.cell_extents[d2] / data.cell_extents[d1];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2] / data.length[d1];
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2] / data.cell_extents[d1];
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2]
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2]
/ data.volume_element;
return;
}
for (unsigned int i=0; i<output.size(); ++i)
for (unsigned int d1=0; d1<dim; ++d1)
for (unsigned int d2=0; d2<dim; ++d2)
- output[i][d1][d2] = input[i][d1][d2] * data.length[d2]
- / data.length[d1] / data.volume_element;
+ output[i][d1][d2] = input[i][d1][d2] * data.cell_extents[d2]
+ / data.cell_extents[d1] / data.volume_element;
return;
}
for (unsigned int k=0; k<spacedim; ++k)
{
- output[q][i][j][k] = input[q][i][j][k] / data.length[j] / data.length[k];
+ output[q][i][j][k] = input[q][i][j][k] / data.cell_extents[j] / data.cell_extents[k];
}
}
for (unsigned int k=0; k<spacedim; ++k)
{
output[q][i][j][k] = input[q][i][j][k]
- * data.length[i]
- / data.length[j]
- / data.length[k];
+ * data.cell_extents[i]
+ / data.cell_extents[j]
+ / data.cell_extents[k];
}
return;
}
for (unsigned int k=0; k<spacedim; ++k)
{
output[q][i][j][k] = input[q][i][j][k]
- / data.length[i]
- / data.length[j]
- / data.length[k];
+ / data.cell_extents[i]
+ / data.cell_extents[j]
+ / data.cell_extents[k];
}
return;
for (unsigned int k=0; k<spacedim; ++k)
{
output[q][i][j][k] = input[q][i][j][k]
- * data.length[i]
+ * data.cell_extents[i]
/ data.volume_element
- / data.length[j]
- / data.length[k];
+ / data.cell_extents[j]
+ / data.cell_extents[k];
}
return;