how to use culaDeviceSgels in C

General CULA Dense (LAPACK & BLAS) support and troubleshooting. Use this forum if you are having a general problem or have encountered a bug.

how to use culaDeviceSgels in C

Postby sawyer » Sat Jan 11, 2014 11:15 pm

Hi, I'm new in CULA and get some troubles.
1. the matrix is in col major,i want get the x where Ax=B in least square solution.A demension is m×n,so x is n×1 ,B is m×1. The problem is I copy A and B to device and set them in culaDeviceSgels , how I get x. The dimension of B is different from x. I dont know how to copy x to the host.
Code: Select all
   //A ,B is given,and m>=n
        float* d_A;
   float* d_B;
   cudaMalloc((void**)&d_A,sizeof(float)*m*n); //allocate device memory for d_A
   cudaMalloc((void**)&d_B,m*sizeof(float)); //I allocate device memory  for d_B
         //Then how I copy B and get x??????

2.if A and B are both in row-major ,how I call the function?
Posts: 1
Joined: Fri Jan 10, 2014 9:02 am

Return to CULA Dense Support

Who is online

Users browsing this forum: Yahoo [Bot] and 1 guest