Example #1
0
int rDiagonal(int nDim,...) 
{ va_list ap;
  REAL*MassM=malloc(sizeof(REAL)*nDim*nDim);
  int i,j,id;
   
  va_start(ap,nDim);
  for(i=0;i<nDim;i++)for(j=i;j<nDim;j++) MassM[sMT(i,j)]=va_arg(ap, REAL); 
//for(i=0;i<nDim;i++)for(j=i;j<nDim;j++) printf("%d %d %E\n",i,j, (doubble)MassM[sMT(i,j)]);
  va_end(ap);

  if(idCur>idLIM) idCur=0;
  id=idCur++;
  extendData(id,nDim,1);
  FError=FError|rJacobi(MassM, nDim, ev[id], rV[id]); 
  free(MassM);
//for(i=0;i<nDim;i++) printf(" %E ",(double)ev[id][i]);
//printf("\n");  

  return id;
}
Example #2
0
int rjacobi_(double*a,int*n,double*d,double*v){ return rJacobi(a,*n,d,v); }