You haven't given the elements of fvalues any data yet. It is merely an empty array (albeit with default values) the size of your rows.
And then the whole forloop you've got going doesn't make sense because, like I said, you didn't create a multidimensional array. So you are trying to do  operations when you only have  defined. Make sense?
I except you are getting errors along side these problems but you failed to post those.