00001 #include "cs.h"00002 /* x = b(p), for dense vectors x and b; p=NULL denotes identity */00003intcs_pvec (constint *p, constdouble *b, double *x, int n)
00004 {
00005 int k ;
00006 if (!x || !b) return (0) ; /* check inputs */00007 for (k = 0 ; k < n ; k++) x [k] = b [p ? p [k] : k] ;
00008 return (1) ;
00009 }