Code Monkey home page Code Monkey logo

unsat-frac's Introduction

DOI

unsat-frac: A PorePy extension package for simulating the saturated-unsaturated flow in fractured porous media

unsat-frac is a Python package created as an extension of PorePy for modeling and simulation of the unsaturated flow with fractures acting as capillary barriers.

Citing

If you use unsat-frac in your research, we ask you to cite the following reference:

Varela, J., Keilegavlen, E., Nordbotten, J. M., & Radu, F. A. (2023). A Model for Saturated-Unsaturated Flow with Fractures Acting as Capillary Barriers. Authorea Preprints.

Installation from source

unsat-frac is developed under Python >= 3.9. Get the latest version by cloning this repository, i.e.:

git clone https://github.com/jhabriel/unsat-frac.git
cd unsat-frac

Now, install the dependencies:

 pip install -r requirements.txt

unsat-fract requires PorePy (commit b5ddf54cf5e71ee96ec8526234f24a1ee6a81a1c) to be installed. If you do not have PorePy installed, please do so before installing unsat-frac.

To install unsat-frac:

pip install .

Or, for user-editable installations:

pip install --editable .

Examples

All the numerical examples included in the manuscript can be found in the paper_examples folder.

Troubleshooting

Create an issue.

License

See license md.

unsat-frac's People

Contributors

jhabriel avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

unsat-frac's Issues

Solve issue with scaling of mortar fluxes

In the volume conservation equation for lower-dimensional subdomains: Should we use the integrated mortar fluxes (the one given by default by PorePy) or should we scale by the mortar cell volume and effectively use the normal velocities?

Change calculation of error so that init_res_norm is well-defined

Specifically, we would like to avoid init_res_norm to be potentially non-defined:

# Compute 'error' as norm of the residual
res_norm = np.linalg.norm(b, 2)
if itr == 0:
    init_res_norm = res_norm
else:
    inti_res_norm = max(res_norm, init_res_norm)
rel_res = res_norm / init_res_norm

Projection of traces from higher- to lower-dimensional subdomains, only takes into account the bulk

The trace operator currently takes into account only the projection of the traces from the internal boundary of the bulk onto the highest-dimensional interfaces. If one wants to project from 1D to 0D, these are filled with zeros. Naturally, this creates a difference in hydraulic head and consequently an artificial mortar flux.

A correct definition of the projection operators should solve this issue.

Representative fracture pressure threshold

The pressure threshold in a fracture is not well defined when the fracture neighbors two different types of soils. This introduces a problem since the water volume correction depends on this value.

A possible solution is to introduce a representative fracture pressure threshold. This will be a single number representing a sort of equivalent pressure threshold for the fracture.

The natural way to define it will be as a weighted average, where the weights include the area occupied by the specific type of soil.

Bug in determination of conductivity state of lower-dimensional mortar cells

Currently, the conductivity state (1 = conductive, 0 = blocking) in lower-dimensional mortar cells is not computed correctly. This depends on wheter the projected hydraulic heads from the lower- and higher-dimensional neighboring subdomains are either dry or wet. However, there is currently an inconsistency.

Indeed, the problem seems to be deeper and related to the values of "dry" hydraulic head being different when using ghost cells.

Plausible solutions:

  1. Use the value of pressure head to determine wheter a mortar cell is conductive or blocking. We might even consider using the pressure head in the interface flux calculation (think a bit more about this, does it make sense?)

Create data_exporter class for each numerical example

A new class DataExporter must be created, for each numerical example. This class has to be able to effectively store primary and secondary variables, i.e., hydraulic_head, pressure_head, water_volume, water_table_height, water_content, saturation, etc.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.