Noted. So I have verified this with the following code.
#include <deal.II/base/quadrature_lib.h>
#include <deal.II/base/point.h>
#include <deal.II/fe/fe_dgq.h>
#include <iostream>
#include <cmath>
#include <vector>
using namespace dealii;
int main(int argc, char **argv)
{
const int degree = 4;
const int n_poly1 = degree+1;
const FE_DGQLegendre<1> fe1(degree);
const FE_DGQLegendre<3> fe3(degree);
const QGauss<3> quad(degree+1);
const int n_qp = quad.size();
const std::vector<Point<3>>& points = quad.get_points();
const std::vector<double>& weights = quad.get_weights();
for(int k=0; k<n_poly1; k++){
for(int j=0; j<n_poly1; j++){
for(int i=0; i<n_poly1; i++){
int index_3d = i + j*n_poly1 + k*n_poly1*n_poly1;
// compute error between 'index_3d'-th polynomial of 'fe3' and the product of
// i-th, j-th and k-th polynomials of 'fe1'
double error = 0;
for(int q=0; q<n_qp; q++){
error += weights[q]*std::pow(
fe3.shape_value(index_3d, points[q]) - (
fe1.shape_value(i, Point<1>(points[q][0]))*
fe1.shape_value(j, Point<1>(points[q][1]))*
fe1.shape_value(k, Point<1>(points[q][2]))
),
2
);
}
std::cout << "Tensor indices: " << i << " " << j << " " << k << ", "
<< "3d index: " << index_3d << ", error: " << error << "\n";
}
}
}
}
And the output shows all errors to be 0! If this is ok, I will create a pr with a patch to the documentation shortly.