One thing that may help you visualize what's going on is to use meaningful names in your loops, instead of i and j. For example
Code:
for(int Row =0; Row < RIDU; Row++)
{
    for(int Column = 0; Column < VEERGE; Column++)
    {