Edited Cuda Solve