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

What is 'GeoMesh' wrapper?

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   November 3, 2020, 08:08
Default What is 'GeoMesh' wrapper?
  #1
Senior Member
 
Mandeep Shetty
Join Date: Apr 2016
Posts: 188
Rep Power: 10
granzer is on a distinguished road
Hello, can someone please explain what the GeoMesh wrapper class does? I know it is used to wrap volMesh, surfaceMesh, pointMesh, but what does wrapping these meshes with GeoMesh achieve?

Also, volMesh, surfaceMesh, pointMesh themselves seem to be derived by wrapping the fvMesh class with GeoMesh. Why is this done?
granzer is offline   Reply With Quote

Old   November 6, 2020, 14:56
Default
  #2
Senior Member
 
Mandeep Shetty
Join Date: Apr 2016
Posts: 188
Rep Power: 10
granzer is on a distinguished road
Quote:
Originally Posted by granzer View Post
Hello, can someone please explain what the GeoMesh wrapper class does? I know it is used to wrap volMesh, surfaceMesh, pointMesh, but what does wrapping these meshes with GeoMesh achieve?

Also, volMesh, surfaceMesh, pointMesh themselves seem to be derived by wrapping the fvMesh class with GeoMesh. Why is this done?
Any info on this please?
granzer is offline   Reply With Quote

Old   November 7, 2020, 14:38
Default
  #3
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
I think:

For a given utility (e.g. decomposePar), GeoMesh template gives access to all types of meshes. Therefore, say decomposePar, can be executed for all mesh types that GeoMesh wraps. Benefit: easier maintainability, lesser code, better structure etc.
HPE is offline   Reply With Quote

Old   November 8, 2020, 01:56
Default
  #4
Senior Member
 
Mandeep Shetty
Join Date: Apr 2016
Posts: 188
Rep Power: 10
granzer is on a distinguished road
@HPE thank you for your answer. Yes I have seen it used in few places. Especially in GeometricField(Field, PatchField, GeoMesh) class. Here the GeoMesh can be volMesh or surfaceMesh etc. Let's say it's volMesh. The volMesh class inherits from GeoMesh<fvMesh> class. Why not inherit directly from fvMesh. Why use GeoMesh<fvMesh> (correct me if I am wrong...here 'fvMesh' is wrapped by 'GeoMesh' class right?)
granzer is offline   Reply With Quote

Old   November 8, 2020, 01:57
Default
  #5
Senior Member
 
Mandeep Shetty
Join Date: Apr 2016
Posts: 188
Rep Power: 10
granzer is on a distinguished road
Quote:
Originally Posted by HPE View Post
I think:

For a given utility (e.g. decomposePar), GeoMesh template gives access to all types of meshes. Therefore, say decomposePar, can be executed for all mesh types that GeoMesh wraps. Benefit: easier maintainability, lesser code, better structure etc.
@HPE thank you for your answer. Yes I have seen it used in few places. Especially in GeometricField(Field, PatchField, GeoMesh) class. Here the GeoMesh can be volMesh or surfaceMesh etc. Let's say it's volMesh. The volMesh class inherits from GeoMesh<fvMesh> class. Why not inherit directly from fvMesh. Why use GeoMesh<fvMesh> (correct me if I am wrong...here 'fvMesh' is wrapped by 'GeoMesh' class right?).
granzer is offline   Reply With Quote

Reply

Tags
geomesh, wrapper


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


Similar Threads
Thread Thread Starter Forum Replies Last Post
Help with if statement CHARLES OpenFOAM Programming & Development 17 August 22, 2021 04:14
Elementwise multiplication operator johndeas OpenFOAM Running, Solving & CFD 3 March 9, 2019 14:03
adding compressible option to ptot immortality OpenFOAM Programming & Development 13 June 15, 2015 16:00
Sampling rhoFlux in electrostaticFoam sverdoold OpenFOAM Post-Processing 14 November 16, 2010 17:19
A stupid question luckyluke OpenFOAM Running, Solving & CFD 14 August 13, 2007 05:25


All times are GMT -4. The time now is 16:54.