I am getting the same value on using the sizeOf operator for a matrix of size 100*100 and 1*1 respectively.
mat A(100,100),B(1,1);
A.randu();
B.randu();
cout<<"Memory requested for A:"<<sizeOf(A);
cout<<"Memory requested for B:"<<sizeOf(B);
Output:
Memory requested for A:160
Memory requested for B:160
Well how do I get the actual memory required by the code for each variable A,B.