optframework.dpbe.dpbe_core module

Solving 1D, 2D and 3D discrete population balance equations for agglomerating systems.

class optframework.dpbe.dpbe_core.DPBECore(base)[source]

Bases: object

full_init(calc_alpha=True, init_N=True)[source]

Fully initialize a population instance.

This method calls
  • pop.calc_R( )

  • pop.init_N( )

  • pop.calc_alpha_prim( ) (optional)

  • pop.calc_F_M( )

  • pop.calc_B_M( )

Parameters

calc_alphabool, optional

If True, calculate collision efficiency values from provided material data. If False, use pop.alpha_prim (initialize beforehand!)

calc_R()[source]

Initialize the discrete calculation grid for particle radii, volumes, and volume fractions.

This method calculates and initializes the radii (R), total volumes (V), and material volume fractions (Xi_vol) for each class of particles. The results are stored in the class attributes self.V, self.R, and self.Xi_vol.

  • For the 1D case, this method generates a grid for total volumes and radii.

  • For the 2D case, this method generates a grid for combined volumes of two particle types (V1 and V3) and calculates the corresponding radii and volume fractions.

Parameters

None

Notes

  • For uniform (uni) grids, the total volumes are directly proportional to the particle class index.

  • For geometric (geo) grids, the volume edges (V_e) are calculated first using parameters NS (number of grid points) and S (scaling factor). The actual grid nodes (V) are then calculated as the midpoints between these volume edges.

  • Agglomeration criteria are also handled to prevent integration issues for large agglomerate sizes by limiting the agglomeration process at critical points.

init_N(reset_N=True, reset_path=True, N01=None, N02=None, N03=None)[source]

Initialize discrete number concentration array.

Creates the following class attributes:
  • pop.N: Number concentration of each class

calc_F_M()[source]

Initialize agglomeration frequency array.

Creates the following class attributes:
  • pop.F_M: (2D)Agglomeration frequency between two classes ij and ab is stored in F_M[i,j,a,b]

calc_B_R()[source]

Initialize breakage rate array.

Creates the following class attributes:
  • pop.B_R: (2D)Breakage rate for class ab. The result is stored in B_R[a,b]

calc_int_B_F()[source]

Initialize integrated breakage function array.

Creates the following class attributes:
  • pop.int_B_F: (2D)The integral of the breakage function from class ab to class ij. Result is stored in int_B_F[a,b,i,j]

  • pop.intx_B_F: (2D)The integral of the (breakage function*x) from class ab to class ij. Result is stored in intx_B_F[a,b,i,j]

  • pop.inty_B_F: (2D)The integral of the (breakage function*y) from class ab to class ij. Result is stored in inty_B_F[a,b,i,j]

calc_alpha_prim()[source]

Calculate collision efficiency between primary particles based on material data.

int_fun(s, a, i, b=None, j=None, c=None, k=None, comb_flag=0)[source]
solve_PBE(t_vec=None)[source]

Method for solving the (previously initialized) population with scipy.solve_ivp.

Parameters

t_maxfloat, optional

Final agglomeration time in seconds.

t_vecarray_like, optional

Points in time (in seconds) at which to export the numerical solution.