Changeset 790 for sans/XOP_Dev/MonteCarlo/DebyeSpheres.c
- Timestamp:
- Feb 16, 2011 5:39:25 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
sans/XOP_Dev/MonteCarlo/DebyeSpheres.c
r789 r790 241 241 int npt,numBins,binIndex; 242 242 double grid,binWidth,val; 243 int p1,p2; 243 244 244 245 … … 283 284 npt = (int) WavePoints(p->xwavH); //wavePoints returns long, number of XYZ points 284 285 numBins = (int) WavePoints(p->bwavH); //wavePoints returns long, number of points in bin wave 286 p1 = (int) p->p1; 287 p2 = (int) p->p2; 288 285 289 286 290 xv = WaveData(p->xwavH); //xyz locations … … 293 297 294 298 //do the i!=j double loop, 295 for(i= 0;i<npt;i+=1) {299 for(i=p1;i<p2;i+=1) { 296 300 for(j=(i+1);j<npt;j+=1) { 297 301 val = XYZDistance(xv[i],xv[j],yv[i],yv[j],zv[i],zv[j])*grid; … … 329 333 int npt,numBins,binIndex; 330 334 double grid,binWidth,val,retVal; 335 int p1,p2; 336 331 337 332 338 // for accessing the 2D wave data to write the results … … 418 424 PSFid = WaveData(p->PSFidH); //this one is 2D 419 425 426 p1 = (int) p->p1; 427 p2 = (int) p->p2; 428 420 429 grid = p->grid; 421 430 binWidth = p->binWidth; 422 431 423 432 //do the i!=j double loop, 424 for(i= 0;i<npt;i+=1) {433 for(i=p1;i<p2;i+=1) { 425 434 for(j=(i+1);j<npt;j+=1) { 426 435 val = XYZDistance(xv[i],xv[j],yv[i],yv[j],zv[i],zv[j])*grid;
Note: See TracChangeset
for help on using the changeset viewer.