reservoirflow.models.Compositional.compile#

Compositional.compile(stype: str, method: str, sparse: bool = True)#

Build a solution (equation system) for the model.

This function will add model.solution and model.compiler which are defined based on the parameters used in this function. In addition, methods model.solve() and model.run() are actually mapped from model.solution.

Note that methods solve() and run() in addition to many other methods can be accessed using the solution object (e.g. model.solution.run()). For more information about the assigned solution object, check the documentation.

Parameters:
  • stype (str) – solution type in ['numerical', 'analytical', 'neurical'].

  • method (str) –

    solution method as following:

    • ’numerical’ methods: ['FDM', 'FVM', 'FEM'].

    • ’analytical’ methods: ['1D1P', '1D2P', etc.].

    • ’neurical’ methods: ['PINN', 'DeepONet', etc.].

  • sparse (bool, optional, default: True) – using sparse computing for a better performance.