-
Notifications
You must be signed in to change notification settings - Fork 406
EB anisotropic meshes - changes for cut_face_2d routine #4554
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
@nataraj2 @WeiqunZhang -- take a look at the calling sequences -- note in cut_faces_2d we have Real axm, Real axp, Real aym, Real ayp, Real bcx, Real bcy, Real dxval, Real dyval) The point being that for the areas, the bcs and the d*val, the "x" version always comes before the "y" version. Look now at the calling sequences, e.g. lzm,lzp,lym,lyp,bcy,bcz,dx[2],dx[1]) Note that Mahesh's changes match -- dx[2] comes before dx[1] and lzm comes before lym ... but bcy comes before bcz. This seems wrong?? |
Yes, I agree with @asalmgren that the orders seem wrong. I think they should always be dx[i] following by dx[j], where i < j. That's how we order face centroids. For y-face centroid, component 0 is for x and 1 for z. |
Other than the order of dx, LGTM. We probably also want to fix Sx2, Sy2 and Sxy in the future. They are used in build_cells that does the least squares fit. |
I don't think this is correct. Are you saying there is a bug even in the uniform size case? |
See image below for the terminology used in the
|
This PR makes the necessary changes in the variables -
areafrac
,nx
,ny
,centx
,centy
,Sx2
,Sy2
,Sxy
, in thecut_face_2d
routine, for anisotropic meshes (ie. when mesh spacings are not equal). The derivation is in the attached pdf in the link below. The changes are in Eqns. 35-37, 43-44, 46-47, 49-50, 55-56.EB_anisotropic.pdf
Summary
Additional background
Checklist
The proposed changes: