Skip to content

Reply To: How to create complex 2D geometry stucture


Its certainly possible to read in external data to set the material numbers. E.g. one possibility that I have encountered in (non-OpenLB) example codes is to read in a bitmap image file to set geometry information. All you would need is some loop to iterate over the input data and set the material numbers using e.g. SuperGeometry2D::get.

However the most straight forward way is to use the OpenLB-provided interfaces, specifically indicators in combination with the rename functions. See e.g. examples/laminar/cylinder2d for a basic example. What specifically do you want to model?

(In 3D we support CAD import via STL data)