flopy.mfusg.mfusgcln module

Mfusgcln module.

Contains the MfUsgCln class. Note that the user can access the MfUsgCln class as flopy.mfusg.MfUsgCln.

Compatible with USG-Transport Version 1.7.0. which can be download from https://www.gsi-net.com/en/software/free-software/modflow-usg.html

Additional information for this MODFLOW package can be found at the `Online MODFLOW Guide Panday, S., 2021; USG-Transport Version 1.7.0: The Block-Centered Transport Process for MODFLOW-USG, GSI Environmental, March, 2021

Panday, Sorab, Langevin, C.D., Niswonger, R.G., Ibaraki, Motomu, and Hughes, J.D., 2013, MODFLOW–USG version 1: An unstructured grid version of MODFLOW for simulating groundwater flow and tightly coupled processes using a control volume finite-difference formulation: U.S. Geological Survey Techniques and Methods, book 6, chap. A45, 66 p.

class MfUsgCln(model, ncln=None, iclnnds=None, nndcln=None, clncon=None, nja_cln=None, iac_cln=None, ja_cln=None, node_prop=None, nclngwc=None, cln_gwc=None, nconduityp=1, cln_circ=None, ibound=1, strt=1.0, transient=False, printiaja=False, nrectyp=0, cln_rect=None, bhe=False, grav=None, visk=None, extension=('cln', 'clncb', 'clnhd', 'clndd', 'clnib', 'clncn', 'clnmb'), unitnumber=None, filenames=None)[source]

Bases: Package

Connected Linear Network (CLN) Package class for MODFLOW-USG.

Parameters:
  • model (model object) – The model object (of type flopy.modflowusg.mf.Modflow) to which this package will be added.

  • ncln (int) – is a flag or the number of CLN segments. If NCLN = 0, this flag indicates that the CLN domain connectivity is input in a general IA-JA manner as is used for the GWF Process.If NCLN > 0, linear CLN segments (for instance multi-aquifer wells) or simple CLN networks are simulated and NCLN is the total number of CLN segments in the domain.

  • iclnnds (int) – is a flag or number of CLN-nodes simulated in the model. Multiple CLN-nodes constitute a segment.If ICLNNDS < 0, the CLN-nodes are ordered in a sequential manner from the first CLN node to the last CLN node. Therefore, only linear CLN segments are simulated since a CLN segment does not share any of its nodes with another CLN segment. If ICLNNDS > 0, CLN networks can be simulated and ICLNNDS is the total number of CLN-nodes simulated by the model (NCLNNDS). CLN nodes can be shared among CLN segments and therefore, the CLN-nodal connectivity for the network is also required as input.

  • nndcln (list of int) – is the number of CLN-nodes that are associated with each CLN segment. Only read if NCLN > 0. If ICLNNDS < 0, sum of nndcln is the total number of CLN-nodes (NCLNNDS)

  • clncon (list of list) – are the CLN-node numbers associated with each CLN segment. Only read if NCLN > 0 and ICLNNDS > 0. It is read NCLN times, once for each CLN segment. The number of entries for each sublist is the number of CLN cells (NNDCLN) associated with each CLN segment

  • nja_cln (int) – is the total number of connections of the CLN domain. NJA_CLN is used to dimension the sparse matrix in a compressed row storage format.

  • iac_cln (list of int) – is a matrix indicating the number of connections plus 1 for each CLN node to another CLN node. Note that the IAC_CLN array is only supplied for the CLN cells; the IAC_CLN array is internally expanded to include other domains if present in a simulation. sum(IAC)=NJAG

  • ja_cln (list of list) – is a list of CLN cell number (n) followed by its connecting CLN cell numbers (m) for each of the m CLN cells connected to CLN cell n. This list is sequentially provided for the first to the last CLN cell. Note that the cell and its connections are only supplied for the CLN cells and their connections to the other CLN cells using the local CLN cell numbers.

  • node_prop (matrix) – [IFNO IFTYP IFDIR FLENG FELEV FANGLE IFLIN ICCWADI X1 Y1 Z1 X2 Y2 Z2] is a table of the node properties. Total rows equal the total number of CLN-nodes (NCLNNDS). The first 6 fields is required for running model. Rest of fields have default value of 0.

  • nclngwc (int) – is the number of CLN to porous-medium grid-block connections present in the model. A CLN node need not be connected to any groundwater node. Conversely, a CLN node may be connected to multiple groundwater nodes, or multiple CLN nodes may be connected to the same porous medium mode.

  • cln_gwc (matrix) –

    unstructured: [IFNOD IGWNOD IFCON FSKIN FLENGW FANISO ICGWADI] structured: [IFNOD IGWLAY IGWROW IGWFCOL IFCON FSKIN FLENGW FANISO

    ICGWADI]

    is a table define connections between CLN nodes and groundwater cells. Total rows of the table equals nclngwc.

  • nconduityp (int) – is the number of circular conduit-geometry types.

  • cln_circ – [ICONDUITYP FRAD CONDUITK TCOND TTHK TCFLUID TCONV] is a table define the circular conduit properties. Total rows of the table equals nconduityp. Last 4 fields only needed for heat transport simulation.

  • ibound (1-D array) – is the boundary array for CLN-nodes. Length equal NCLNNDS

  • strt (1-D array) – is initial head at the beginning of the simulation in CLN nodes. Length equal NCLNNDS

  • transient (bool) – if there is transient IBOUND for each stress period

  • printiaja (bool) – whether to print IA_CLN and JA_CLN to listing file

  • nrectyp (int) – is the number of rectangular conduit-geometry types.

  • cln_rect (rectangular fracture properties) – [IRECTYP FLENGTH FHEIGHT CONDUITK TCOND TTHK TCFLUID TCONV] is read for each rectangular conduit. Total rows of the table equals nrectyp. Last 4 fields only needed for heat transport simulation.

  • bhe (bool) – is a flag indicating that bhe details are also included in a heat transport model. Specifically, the thermal conductance and bhe tube thickness are included in transfer of heat between groundwater and CLN cells along with the heat conductivity of the bhe fluid and the convective heat transfer coefficient.

  • grav (float) – is the gravitational acceleration constant in model simulation units. The value of the constant follows the keyword GRAVITY. Note that the constant value is 9.81 m/s2 in SI units; 32.2 ft/s2 in fps units.

  • visk (float) – is the kinematic viscosity of water in model simulation units [L2/T]. The value of kinematic viscosity follows the keyword VISCOSITY. Note that the constant value is 1.787 x 10-6 m2/s in SI units; 1.924 x 10-5 ft2/s in fps units.

  • extension (list of strings) – (default is [‘cln’,’clncb’,’clnhd’,’clndd’,’clnib’,’clncn’,’clnmb’]).

  • unitnumber (list of int) – File unit number for the package and the output files. (default is [71, 0, 0, 0, 0, 0, 0] ).

  • filenames (list of str) – Filenames to use for the package and the output files. If filenames = None the package name will be created using the model name and package extensions.

Notes

Examples

>>> import flopy
>>> ml = flopy.mfusg.MfUsg()
>>> node_prop = [[1,1,0,10.0,-110.0,1.57,0,0],[2,1,0,10.0,-130.0,1.57,0,0]]
>>> cln_gwc = [[1,1,50,50,0,0,10.0,1.0,0],[2,2,50,50,0,0,10.0,1.0,0]]
>>> cln = flopy.mfusg.MfUsgCln(ml, ncln=1, iclnnds=-1, nndcln=2,
        nclngwc = 2, node_prop =node_prop, cln_gwc =cln_gwc)
property cln_nodes

Returns the total number of CLN nodes.

classmethod load(f, model, pak_type='cln', ext_unit_dict=None, **kwargs)[source]

Load an existing package.

Parameters:
  • f (filename or file handle) – File to load.

  • model (model object) – The model object (of type flopy.modflow.mf.Modflow) to which this package will be added.

  • ext_unit_dict (dictionary, optional) – If the arrays in the file are specified using EXTERNAL, or older style array control records, then f should be a file handle. In this case ext_unit_dict is required, which can be constructed using the function flopy.utils.mfreadnam.parsenamefile.

Returns:

cln

Return type:

MfUsgCln object

Examples

>>> import flopy
>>> m = flopy.modflow.Modflow()
>>> cln = flopy.mfusg.MfUsgCln.load('test.cln', m)
write_file(f=None, check=False)[source]

Write the package file.

Parameters:

f (filename or file handle) – File to write to.

Return type:

None