Skip to content

Need help creating and simulating a microfluidic porous geometry with inlet and outlet manifolds #3005

@zdanshah-hub

Description

@zdanshah-hub

Hello everyone 👋

I am working on a microfluidic porous design that looks like this:

microfluidic_geometry

It has:

  • Two symmetric manifolds (inlet and outlet)
  • A random irregular porous structure in the middle
  • The goal is to simulate flow or diffusion through this geometry

🔍 What I want to do

I want to:

  1. Generate this type of geometry programmatically in Python using OpenPNM or PoreSpy
    (not just from a picture — I want full control over pore size, shape, and connectivity).
  2. Connect the manifolds and porous core seamlessly, so that flow enters from the left manifold and exits from the right one.
  3. Run simulations such as:
    • Stokes Flow for pressure-driven flow
    • Fickian Diffusion for transient hydrogen diffusion
  4. Visualize the flow through the porous region — ideally animated to show how gas or liquid moves inside.
  5. Export the geometry or network (STL, VTK, or similar) for further CFD validation in COMSOL or ANSYS.

🧠 What I’ve already tried

  • Created random porous structures using porespy.generators.blobs()
  • Used ps.networks.snow2() for network extraction
  • Added manifolds manually using Shapely polygons
  • Imported the network into OpenPNM using op.io.network_from_porespy()
  • Ran diffusion and flow simulations successfully, but:
    • The manifolds do not merge smoothly with the porous region
    • The flow visualization looks unrealistic near the boundary
    • I cannot easily control pore and throat parameters near the inlet/outlet

💡 What I need help with

  1. Is there a recommended way to generate manifold-connected porous geometries in PoreSpy or OpenPNM?
  2. How can I assign custom pore regions or boundary conditions (for example, define the manifold pores explicitly)?
  3. Are there any examples of microfluidic or chip-scale flow simulations using OpenPNM that I can study or adapt?
  4. What is the best way to export this geometry for CFD post-processing (e.g., STL or VTK format)?

⚙️ My environment

  • Python 3.10
  • openpnm 3.5.2
  • porespy 2.3
  • shapely, scikit-image, matplotlib
  • Platform: Google Colab

Any examples, guidance, or best practices would be greatly appreciated.
I’m especially interested in realistic microfluidic pore design and flow visualization techniques.

Thank you for your time and help 🙏
@[openpnn

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions