Skip to content
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

Throat cross-sectional area calculation is wrong when using high accuracy with real voxel sizes. #828

Open
wants to merge 1 commit into
base: dev
Choose a base branch
from

Conversation

Cesar-Timana
Copy link

Hello everyone,
There is an error in calculating the throat cross-sectional area using the high accuracy method.

The surface area used as input has to be without multiplying by the voxel size.

The following test demonstrates the problem:

import porespy as ps
import numpy as np
import openpnm as op
np.random.seed(13)

resolution = 5e-7

im = ps.generators.overlapping_spheres([100, 100, 100], r=7, porosity=0.7)

snow_output = ps.networks.snow2(im,
                   voxel_size=resolution,
                   boundary_width=3,
                   accuracy='high', # high
                   parallelization=None)

pn = op.io.network_from_porespy(snow_output.network)

A = pn['throat.cross_sectional_area']
print(A[1:10])

When subtracting the surface area of merged regions from the isolated region surface areas, they need to be in the same unit.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant