In my application, i consider 2 pointer on 2 array.
double *Qi1=new double[ni1];
double *Qi=new double[ni];
"i" and "i1"(=i-1) are 2 dates.
So, as we could see date i-1 is before date i. In my application i need to know all the value in the array which is pointed by Qi1, to calculate new values in the second array pointed by Qi(we note that ni>=ni1).
But, my pb is that as my application is iterative i do a for loop on the "i", so that at the end of all my calculation, just before going to the next step of the loop, i want that Qi "becomes" Qi1, like that i could continue the iteration, so i think that i have to do a reallocation of my tabs, and i don't know how we could do that. So could you give me a solution?
thanks in advance
jayjay
double *Qi1=new double[ni1];
double *Qi=new double[ni];
"i" and "i1"(=i-1) are 2 dates.
So, as we could see date i-1 is before date i. In my application i need to know all the value in the array which is pointed by Qi1, to calculate new values in the second array pointed by Qi(we note that ni>=ni1).
But, my pb is that as my application is iterative i do a for loop on the "i", so that at the end of all my calculation, just before going to the next step of the loop, i want that Qi "becomes" Qi1, like that i could continue the iteration, so i think that i have to do a reallocation of my tabs, and i don't know how we could do that. So could you give me a solution?
thanks in advance
jayjay