From the C ++ standard, referring to the operator sizeof:
When applied to an array, the result is the total number of bytes in the array. This means that the size of the array of elements nis ntimes the size of the element.
From this, I would say that double[4][4]they double[16]should have the same basic idea.
Ie given
sizeof(double[4]) = 4*sizeof(double)
and
sizeof(double[4][4]) = 4*sizeof(double[4])
then we have
sizeof(double[4][4]) = 4*4*sizeof(double) = 16*sizeof(double) = sizeof(double[16])
, , , , , , . , . , .
++ , , - .