Calculating Distance
Z-K-L opened this issue · comments
Why magrobs_[iObs][iSurf][i] = mag(robs_[iObs][iSurf][i]) is not used, instead caculated the |r| = (-U_0*x/c_0+R)/(1-(U_0/c_0)^2).
Hi, could you please point to the line of source code that confuses you?
at fwhFormulation.C line 236~237
Thank you for the question, I think we should ask latest contributors.
@eacfd @unicfdlab could you please comment this question?
The distance is calculated using the GT formulation. If you use Farassat Formulation (U0 is equal 0) the distance will be equal to
mag(robs_[iObs][iSurf][I]).
magrobs_[iObs][iSurf][i] = (-(mag(fwh_.U0_)/fwh_.c0_) * r[0] + R_)/(1 - sqr(mag(fwh_.U0_)/fwh_.c0_));
if U0=0 then
magrobs_[iObs][iSurf][i] = (0 +R_)/(1-0)
where R_
scalar R_ = sqrt( sqr(r[0])+( 1 - sqr(mag(fwh_.U0_)/fwh_.c0_))*(sqr(r[1]) + sqr(r[2])) );
for U0 = 0
R_ = sqrt( sqr(r[0])+(sqr(r[1]) + sqr(r[2])) );
Thank you!
@unicfdlab , I'm sorry, but I cannot agree with your explanation. magrobs_ array is calculated in fwhFormulation.C, which is common both for GT formulation and Farassat Formulation. Therefore, should we move calculation of magrobs_ (and dependent variables) into different modules ?
@unicfdlab , I'm sorry, but I cannot agree with your explanation. magrobs_ array is calculated in fwhFormulation.C, which is common both for GT formulation and Farassat Formulation. Therefore, should we move calculation of magrobs_ (and dependent variables) into different modules ?
This question has been resolved. R_ is a weighted verison of magrobs_ . Sorry for possible panic.