CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Running, Solving & CFD

symmetryPlane and Eigenvectors

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   February 27, 2021, 18:38
Default symmetryPlane and Eigenvectors
  #1
Senior Member
 
Join Date: Jun 2016
Posts: 102
Rep Power: 10
xuegy is on a distinguished road
Dear FOAMers,

I have a very frustrating bug in my code. I need to calculate 3 eigenvalues (saved as volVectorField) and 3 eigenvectors (saved as volTensorField) in my code. Obviously there's no direction in an eigenvalue vector. It's just 3 numbers. But OpenFOAM automatically cuts my eigenvalues and eigenvectors along the normal direction of the symmetryPlane. This is really really stupid. All I need is zeroGradient (OpenFOAM doesn't allow me to use zeroGradient on symmetryPlane boundaries).
One of the possible solution is to store 3+9=12 scalarFields, and convert it back to a vector/tensor while running. But before doing that, is there any elegant way to resolve this?

Thanks.
xuegy is offline   Reply With Quote

Old   March 6, 2021, 15:02
Default
  #2
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 931
Rep Power: 13
HPE is on a distinguished road
have you solved your problem? out of curiosity, how do you use eigenvalues and eigenvectors within a simulation - as a part of the flow field (or I misunderstood)?

maybe keeping them as vectorField/tensorField instead of vol*Fields could solve the issue?
HPE is offline   Reply With Quote

Old   March 6, 2021, 17:14
Default
  #3
Senior Member
 
Join Date: Jun 2016
Posts: 102
Rep Power: 10
xuegy is on a distinguished road
Quote:
Originally Posted by HPE View Post
have you solved your problem? out of curiosity, how do you use eigenvalues and eigenvectors within a simulation - as a part of the flow field (or I misunderstood)?

maybe keeping them as vectorField/tensorField instead of vol*Fields could solve the issue?
Hello.

Yes I solved this problem by not reading/saving these two fields.

The eigenvalue/vector is used in the diagonalization of the stress tensor, so the tensor can be positive-definite and more stable.

Best
xuegy is offline   Reply With Quote

Old   March 7, 2021, 09:06
Default
  #4
HPE
Senior Member
 
HPE's Avatar
 
Herpes Free Engineer
Join Date: Sep 2019
Location: The Home Under The Ground with the Lost Boys
Posts: 931
Rep Power: 13
HPE is on a distinguished road
just curiosity: would be using ::Internal help for the object to be read/written? e.g. volVectorField::Internal eigenvalues?
HPE is offline   Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 01:24.