I am trying to create a class grid which contains the data members unsigned NR, unsigned NC and it should also contain a 2D array double Coordiantes[NR][NC]. I wish to initialize the data members NR and NC through the class constructor. I am trying to avoid the dynamic allocation of the 2-D array as I prefer contiguous memory allocation so as to avoid the cache misses as much as possible.
I am not sure if it is possible but any inputs would be helpful.
 
     
     
    