I am trying to implement the following loop in cuda …

for i = 1 to n-1

A(i+1:n,i) = A(i+1:n,i) * ( 1 / A(i,i) )â€

â€¦ BLAS 1 (scale a vector)â€

A(i+1:n,i+1:n) = A(i+1:n , i+1:n )

- A(i+1:n , i) * A(i , i+1:n)â€

â€¦ BLAS 2 (rank-1 update)â€

what i have done is this

for(i=0;i<n;i++)

{

p=1/a_h[i*(n+1)+i];

cublasSscal(n,p,&a_d[(i+1)*n+i],sizeof(float));

}

Now for rank 1 update i will have to use sger function as far as i think …

I don know how to use this function as arguments are getting out of control…

I have got one matrix in an array *a…

now can some one help me with this…

I apologize if this question is too easy as i am a beginner …