(result == CUFFT_INVALID_DEVICE){ std::cout <<"Invalid Device Error\n";exit(1); }// Executing FFTcufftExecZ2Z(plan1d, d_a, d_a, CUFFT_FORWARD);//Executing the iFFTcufftExecZ2Z(plan1d, d_a, d_a, CUFFT_INVERSE);// Copying backcudaMemcpy(h_a, d_a,sizeof(double2)*n, ...