PSI update

r1464 | ffr | 2007-02-12 12:20:21 +1100 (Mon, 12 Feb 2007) | 2 lines
This commit is contained in:
Ferdi Franceschini
2007-02-12 12:20:21 +11:00
committed by Douglas Clowes
parent 634f2023b1
commit 3168325921
157 changed files with 29053 additions and 910 deletions

View File

@@ -625,6 +625,10 @@ int findAllowedBisecting(double lambda, MATRIX z1, float fSet[4],
return 0;
}
if(testFunc(userData, fSet, mask) == 1){
return 1;
}
for(psi = .0; psi < 360.; psi += .5){
rotatePsi(om,chi,phi,psi,&ompsi,&chipsi,&phipsi);
fTest[0] = stt;
@@ -638,6 +642,26 @@ int findAllowedBisecting(double lambda, MATRIX z1, float fSet[4],
}
return 1;
}
/*
* if chi close to 0, or 180, try to wrap phi onto om
*/
if(ABS(fTest[2] - .0) < .1 || ABS(fTest[2] - 180.) < .1){
fTest[1] -= fTest[3];
fTest[3] = .0;
if(fTest[1] < 0.){
fTest[1] += 360.;
}
if(fTest[1] > 360.0){
fTest[1] -= 360.;
}
status = testFunc(userData,fTest,mask);
if(status == 1){
for(i = 0; i < 4; i++){
fSet[i] = fTest[i];
}
return 1;
}
}
if(mask[0] == 0) {
/*
* useless: when two theta problem there is no solution