generate#

The generate module contains a function to generate an openpnm.models.network object that contains a 2D network based on input pore data (see metrics for more info on extracting data).


generate_network()#

pore2chip.generate.generate_network(n1, n2, pore_diameters, throat_diameters, coordination_nums, pore_pdf=None, throat_pdf=None, coord_pdf=None, average_coord=None, min_pore_diameter=None, max_pore_diameter=None, min_throat_diameter=None, max_throat_diameter=None, min_coordination=None, max_coordination=None, pore_random_shift=0.2, lone_pores=True, center_channel=None, return_middle_pores=False, sd=0)#

Create 2D OpenPNM network with given pore, throat, and coordination information

Parameters:
  • n1 (int) – Number of desired pores on x-axis

  • n2 (int) – Number of desired pores on y-axis

  • pore_diameters (array) – Array of input pore diameters

  • pore_pdf (array) – Array of pore size probabilities

  • throat_diameters (array) – Array of input throat diameters

  • throat_pdf (array) – Array of throat size probabilities

  • coordination_nums (array) – Array of pore coordination numbers

  • coord_pdf (array) – Array of pore coordination probabilities

  • average_coord (int) – Average coordination number (by default, generation will not target specific average coordination number)

  • lone_pores (Boolean) – Trims pores with no connections (coordination number of zero)

  • center_channel (int) – Number of pores in the center of the network to be connected (allows guaranteed connection from top to bottom)

  • return_middle_pores (Boolean) – Boolean that indicates if the function returns a tuple with the network and an array of indices of moddle pores for the center channel

Returns:

Generated OpenPNM network

Return type:

openpnm.models.network

On this page