C  Groundwater boundary conditions file
C  Generated by pyiwfm
C
C  Boundary condition types:
C  - specified_head: Fixed head at boundary
C  - specified_flow: Fixed flux at boundary
C  - general_head: Head-dependent flux (GHB)
C
C  ==================================================================
C  SPECIFIED HEAD BOUNDARY CONDITIONS
C  ==================================================================
{{ n_specified_head }}                              / N_SPEC_HEAD_BC
{% for bc in specified_head_bcs %}
C  BC ID: {{ bc.id }}, Layer: {{ bc.layer }}, Nodes: {{ bc.nodes|length }}
{{ bc.id|fortran_int(6) }} {{ bc.layer|fortran_int(3) }} {{ bc.nodes|length|fortran_int(5) }}  / BC_ID, LAYER, NNODES
{% for i in range(bc.nodes|length) %}
  {{ bc.nodes[i]|fortran_int(6) }} {{ bc.values[i]|fortran_float(14, 4) }}
{% endfor %}
{% endfor %}
C
C  ==================================================================
C  SPECIFIED FLOW BOUNDARY CONDITIONS
C  ==================================================================
{{ n_specified_flow }}                              / N_SPEC_FLOW_BC
{% for bc in specified_flow_bcs %}
C  BC ID: {{ bc.id }}, Layer: {{ bc.layer }}, Nodes: {{ bc.nodes|length }}
{{ bc.id|fortran_int(6) }} {{ bc.layer|fortran_int(3) }} {{ bc.nodes|length|fortran_int(5) }}  / BC_ID, LAYER, NNODES
{% for i in range(bc.nodes|length) %}
  {{ bc.nodes[i]|fortran_int(6) }} {{ bc.values[i]|fortran_float(14, 4) }}
{% endfor %}
{% endfor %}
C
C  ==================================================================
C  GENERAL HEAD BOUNDARY CONDITIONS
C  ==================================================================
{{ n_general_head }}                              / N_GEN_HEAD_BC
{% for bc in general_head_bcs %}
C  BC ID: {{ bc.id }}, Layer: {{ bc.layer }}, Nodes: {{ bc.nodes|length }}
{{ bc.id|fortran_int(6) }} {{ bc.layer|fortran_int(3) }} {{ bc.nodes|length|fortran_int(5) }}  / BC_ID, LAYER, NNODES
{% for i in range(bc.nodes|length) %}
  {{ bc.nodes[i]|fortran_int(6) }} {{ bc.values[i]|fortran_float(14, 4) }} {{ bc.conductance[i]|fortran_float(14, 6) }}
{% endfor %}
{% endfor %}
