Define h as a double* instead of double[]

int* a1 = new int[SIZE];  // SIZE limited only by OS/Hardware
int a2[SIZE]; // SIZE limited by COMPILER to the size of the stack frame