моя попытка что-то сделать
???double[2]??? summa( const double* pnts, const int n) {
double tmp0,tmp1;
int i;
tmp0 = 0.0;
tmp1 = 0.0;
for(i=0; i<n; ++i) {
tmp0+=*(pnts+2*i);
tmp1+=*(pnts+2*i+1);
}
// printf("tmp=%lf\n",tmp);
return ????;
}
mod_test=numpy.ctypeslib.load_library('libtest', '.')
mass=numpy.ndarray(2*n,dtype='d')
...
result=mod_test.summa(mass.ctypes.data,n)