Method: NuLin::Native.cpotrf

Defined in:
ext/nulin_native.c

.cpotrf(uplo, n, a, lda, info) ⇒ Object



505
506
507
508
509
510
511
512
513
514
# File 'ext/nulin_native.c', line 505

static VALUE nulin_cpotrf(VALUE self,VALUE uplo,VALUE n,VALUE a,VALUE lda,VALUE info)
{
  char UPLO = StringValueCStr(uplo)[0];
  integer N = NUM2INT(n);
  complex* A = NA_PTR_TYPE((nulin_check_narray(a),a), complex*);
  integer LDA = NUM2INT(lda);
  integer INFO = NUM2INT(info);
  cpotrf_(&UPLO,&N,A,&LDA,&INFO);
  return rb_ary_new3(1, INT2NUM(INFO));
}