You are on page 1of 78

SWAT-MODFLOW Workshop

Prepared By:
Ryan T. Bailey
Dept. of Civil and Environmental Engineering
Colorado State University
rtbailey@engr.colostate.edu

Outline of Workshop
1. Overview of SWAT-MODFLOW
2. Details of MODFLOW
3. Details of SWAT-MODFLOW
4. Setting up a SWAT-MODFLOW Model
5. Groundwater Contaminant Transport using
2
RT3D

Outline of Workshop
1. Overview of SWAT-MODFLOW
2. Details of MODFLOW
3. Details of SWAT-MODFLOW
4. Setting up a SWAT-MODFLOW Model
5. Groundwater Contaminant Transport using
3
RT3D

Overview of SWAT-MODFLOW
Overview

Motivation
MODFLOW
SWATMODFLOW
Setting up
Simulation

Method

Improve groundwater flow (and


solute transport) processes in
SWAT

Link SWAT with physicallybased, spatially-distributed


groundwater models

RT3D

Overview of SWAT-MODFLOW
Overview

MODFLOW

SWATMODFLOW

Linking 3 Models:

SWAT
MODFLOW

- Groundwater model
- 3D finite difference

RT3D

- Reactive transport
- 3D finite difference

Setting up
Simulation
RT3D

Overview of SWAT-MODFLOW
Overview

Linking 3 Models: SWAT

MODFLOW
RT3D

MODFLOW

SWATMODFLOW

ET

Uptake

Setting up
Simulation
RT3D

w
and flo
Overl nsport
a
and tr

Volatilization

Water

Table

Ru
nof

Stream stage
Solute transport

Root Zone
Processes
Vadose Zone
Percolation,
Transport

l
Latera
Flow

Groundwater
discharge
N, P mass loading

Plant
Growth

Groundwater flow
N, P reactive transport

Confining Layer

canal

Pumping
Well
N, P
Concentration

Overview of SWAT-MODFLOW
Timeline of Code Development
Overview

MODFLOW

1. SWAT-MODFLOW code development


2. Add RT3D (contaminant transport)

SWATMODFLOW
Setting up
Simulation
RT3D

3. Test for Several Watersheds


4. Distribute (Publications, Workshops)
5. Add MODFLOW to SWAT Modular code
6. Develop User Interface (linkage, simple MODFLOW)

Overview of SWAT-MODFLOW
Overview

MODFLOW

SWATMODFLOW
Setting up
Simulation

Contributors / Funding
Tyler Wible (Research Associate, CSU)
Mazdak Arabi (Associate Professor, CSU)
Katrin Beiger (Texas A&M AgriLife)
Hendrik Rathjens (Purdue University)
Xiaolu Wei (PhD candidate, CSU)
Jeff Arnold (ARS)

RT3D

Outline of Workshop
1. Overview of SWAT-MODFLOW
2. Details of MODFLOW
3. Details of SWAT-MODFLOW
4. Setting up a SWAT-MODFLOW Model
5. Groundwater Contaminant Transport using
9
RT3D

MODFLOW
Introduction to Groundwater Modeling
Overview

H1

MODFLO
W

SWATMODFLOW

Q
Q

H1

Sand
Setting up
Simulation
RT3D

H
Q KA
L

H2

Screen

H2

10

MODFLOW
Introduction to Groundwater Modeling
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation

Cons. of Mass
+

RT3D

Cons. of Momentum
(Darcys Law)
11

MODFLOW
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation


h

h
h
hK

hK

S
x
y
y

x
x
y
y
t
Darcys Law

RT3D

12

Unconfine
d
Aquifer

MODFLOW
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D


h

h
h
hK

hK

S
x
y
y

x
x
y
y
t


h

h

h
h
K

S
y
z
s
x

x
x
y
y
z

z
t

13

Unconfined
Aquifer

Confined
Aquifer

MODFLOW
Introduction to Groundwater Modeling
Overview

MODFLO
W


h

h
h
hK

hK

S
x

x
x
y
y
t

1. Finite Difference
2. Finite Element

SWATMODFLOW
Setting up
Simulation
RT3D

14

MODFLOW
Introduction to Groundwater Modeling
Overview

MODFLO
W


h

h
h
hK

hK

S
x

x
x
y
y
t

1. Finite Difference
2. Finite Element

SWATMODFLOW
Setting up
Simulation
RT3D

15

MODFLOW
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D

Most widely used


groundwater flow model

3D Flow
Layered systems
Heterogeneous K
Spatial sources/
sinks
Time-variable
sources/sinks
Unconfined/Confine
d

16

MODFLOW
MODFLOW Packages
Overview

Streamflow routing
MODFLO
W

SWATMODFLOW
Setting up
Simulation

Surface water routing


Lake-Groundwater interaction
Reservoir-Groundwater interaction
Unsaturated zone flow
Subsidence and aquifer-system compaction

RT3D

Seawater intrusion

17

MODFLOW
MODFLOW Packages
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D

18

MODFLOW
Basic Inputs
Overview

3D Grid

Lower Arkansas
River Valley

MODFLO
W

SWATMODFLOW

250 m x 250 m grid

Setting up
Simulation
RT3D

19

MODFLOW
Basic Inputs
Overview

MODFLO
W

SWATMODFLOW

Sources and Sinks


Pumping
Canal seepage
Infiltration (rainfall, irrigation)

250 m x 250 m grid

Setting up
Simulation
RT3D

20

MODFLOW
Basic Inputs
Overview

MODFLO
W

SWATMODFLOW

Aquifer Parameters
K
250 m x 250 m grid

Setting up
Simulation
RT3D

21

MODFLOW
Basic Inputs
Overview

MODFLO
W

SWATMODFLOW

Aquifer Parameters
Sy
250 m x 250 m grid

Setting up
Simulation
RT3D

22

MODFLOW
Basic Results
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D

23

MODFLOW
Basic Inputs
Overview

MODFLO
W

SWATMODFLOW

Time Step information


Stress Period: time interval during which input data for all
external stresses are constant
(divided into time steps)

Setting up
Simulation
RT3D

24

MODFLOW
Example Little River Watershed
Overview

MODFLOW

SWATMODFLO
W

3D Steady flow model


Homogeneous K

Setting up
Simulation
RT3D
http://nsidc.org/data/docs/daac/nsidc0329_
smex03_little_river_micronet_ga.html

25

MODFLOW
Example Little River Watershed
Overview

MODFLOW Grid

Aquifer Thickness
2-10 m

MODFLOW

River Cells
SWATMODFLO
W
Setting up
Simulation
RT3D

Active Cells

K = 70 m/day
R = 1.7 mm/day
26

MODFLOW
Example Simulations Little River Watershed
Overview

Simulation Results

MODFLOW

Groundwater Head

Depth to Water Table

SWATMODFLO
W
Setting up
Simulation
RT3D

27

MODFLOW
Input Files
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D

28

MODFLOW
Running Simulation
Overview

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D

29

MODFLOW
Viewing Output
Overview

Head file (.hed)

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D

30

MODFLOW
Viewing Output
Overview

Head file (.hed) GIS

MODFLO
W

SWATMODFLOW
Setting up
Simulation
RT3D

31

MODFLOW
Viewing Output
Head
Overview
MODFLO
W

and Flow file(.hff) Aquifer / River interacti


Leaving Aquifer

SWATMODFLOW
Setting up
Simulation

Entering Aquifer
RT3D

32

MODFLOW
Viewing Output
Head
Overview
MODFLO
W

SWATMODFLOW

and Flow file(.hff) Aquifer / River interacti


Groundwater
Discharge
to Streams

Setting up
Simulation
RT3D

33

Outline of Workshop
1. Overview of SWAT-MODFLOW
2. Details of MODFLOW
3. Details of SWAT-MODFLOW
4. Setting up a SWAT-MODFLOW Model
5. Groundwater Contaminant Transport using
34
RT3D

SWAT-MODFLOW
Overview

MODFLOW

SWATMODFLO
W
Setting up
Simulation
RT3D

Pass data between SWAT and MODFLOW


Objective:

MODFLOW

SWAT
HRUs

Recharge

Channels

Grid Cells

Stream
Stage

GW
River
Discharge Cells

35

SWAT-MODFLOW
Overview

MODFLOW

SWATMODFLO
W
Setting up
Simulation
RT3D

Linking SWAT and MODFLOW:


SWAT

Daily Interactions

Soil percolation
Potential ET not satisfied
River Stage
Pumping required
N, P in percolating water
N, P in stream water

MODFLOW
Water Table height
GW/SW Interaction
Groundwater flows, sources/sinks
36

SWAT-MODFLOW
Overview

Linking Procedure: 1. HRU Grid

Recharge

2. River Cells SubbasinGW Discharge


(Pre-processing tools)

MODFLOW

Disaggregated HRUs
SWATMODFLO
W
Setting up
Simulation
RT3D

MODFLOW Grid
37

SWAT-MODFLOW
Linking Files
Overview

4 Linking Files
swatmf_dhru2hru.txt

MODFLOW

SWATMODFLO
W
Setting up
Simulation

swatmf_dhru2grid.txt
swatmf_grid2dhru.txt
swatmf_river2grid.txt
HRU ID

# of DHRUs

Subbasin ID
DHRU IDs
% Area of DHRU contributing to HRU

RT3D

38

SWAT-MODFLOW
Linking Files
Overview

4 Linking Files
swatmf_dhru2hru.txt

MODFLOW

SWATMODFLO
W
Setting up
Simulation
RT3D

swatmf_dhru2grid.txt
swatmf_grid2dhru.txt
swatmf_river2grid.txt
MODFLOW Cell ID

# of DHRUs contributing to cell


DHRU IDs
% Area of cell that is occupied by DHRU

39

SWAT-MODFLOW
Linking Files
Overview

4 Linking Files
swatmf_dhru2hru.txt

MODFLOW

SWATMODFLO
W
Setting up
Simulation
RT3D

swatmf_dhru2grid.txt
swatmf_grid2dhru.txt
swatmf_river2grid.txt
DHRU ID

# of Cells contributing to DHRU


Row number of Cells
Column number of Cells
% Area of DHRU occupied by cell

40

SWAT-MODFLOW
Linking Files
Overview

4 Linking Files
swatmf_dhru2hru.txt

MODFLOW

SWATMODFLO
W

swatmf_dhru2grid.txt
swatmf_grid2dhru.txt
swatmf_river2grid.txt

Setting up
Simulation
RT3D

River Cell ID

# of Subbasins that cell intersects


Subbasin IDs
Length of channel in Cell

41

SWAT-MODFLOW
Linking Files
Overview

Additional File
swatmf_link.txt

MODFLOW

SWATMODFLO
W
Setting up
Simulation
RT3D

42

SWAT-MODFLOW
Code Structure
Overview

MODFLOW

SWATMODFLO
W
Setting up
Simulation

Read/Allocate MODFLOW
Read SWAT-MODFLOW linkage files
simulate
Years
Days
command
Surface
1: subbasin (hru calculations)
Aquifer

19: MODFLOW
Map SWAT Grid
HRU values disaggregated HRUs (DHRUs)

Recharge

DHRUs Grid cells


River stage MODFLOW River cells

RT3D

Run MODFLOW
Map Grid SWAT
GW Discharge Subbasin streams

Routing

2: Route

43

SWAT-MODFLOW
Calling MODFLOW at Specified Times
Overview

MODFLOW

Linkage Frequency:

SWATMODFLO
W

User-specified

mf_interval

Setting up
Simulation
RT3D

1. If

> mf_interval:

2. If mf_interval >

= mf_interval
Multiple time steps when
MODFLOW44runs

SWAT-MODFLOW
Example Simulations
Overview

Upper Klamath

MODFLOW

MODFLOW Model
- USGS (2012)
- 1970-2004
- 100,000 grid cells

SWAT Model

SWATMODFLO
W

Sprague
Watershed

Setting up
Simulation
RT3D

SWAT Model
Records et al (2014)
Hydrol. Earth Syst. Sci. 18: 45094527

45

SWAT-MODFLOW
Example Simulations
Overview

SWAT MODFLOW Linkage

MODFLOW

Annual Recharge

SWATMODFLO
W
Setting up
Simulation
RT3D

46

SWAT-MODFLOW
Example Simulations
Overview

Simulation Results

MODFLOW

Water Table Elevation

SWATMODFLO
W
Setting up
Simulation
RT3D

47

SWAT-MODFLOW
Example Simulations
Overview

MODFLOW SWAT Linkage

MODFLOW

Groundwater Discharge to Streams

SWATMODFLO
W
Setting up
Simulation
RT3D

48

Outline of Workshop
1. Overview of SWAT-MODFLOW
2. Details of MODFLOW
3. Details of SWAT-MODFLOW
4. Setting up a SWAT-MODFLOW Model
5. Groundwater Contaminant Transport using
49
RT3D

Setting up a Simulation
SWAT Model
Overview

MODFLOW

240 Subbasins

6,233 HRUs

SWATMODFLOW
Setting
up
Simulatio
n
RT3D

50

Setting up a Simulation
MODFLOW Model
Overview

MODFLOW

SWATMODFLOW
Setting
up
Simulatio
n
RT3D

51

Setting up a Simulation
Linking Files
Overview

MODFLOW

SWATMODFLOW
Setting
up
Simulatio
n
RT3D

52

Setting up a Simulation
Linking Files
Overview

hru_dhru
SWATMODFLOW
Setting
up
Simulatio
n
RT3D

4 Input Files

4 Tables

MODFLOW

GIS
Operations

dhru_grid

FORTRAN
Code

swatmf_dhru2hru.txt
swatmf_dhru2grid.txt

grid_dhru

swatmf_grid2dhru.txt

river_grid

swatmf_river2grid.txt

53

Setting up a Simulation
Linking Files
Overview

hru_dhru
SWATMODFLOW
Setting
up
Simulatio
n
RT3D

4 Input Files

4 Tables

MODFLOW

GIS
Operations

dhru_grid

FORTRAN
Code

swatmf_dhru2hru.txt
swatmf_dhru2grid.txt

grid_dhru

swatmf_grid2dhru.txt

river_grid

swatmf_river2grid.txt

54

Setting up a Simulation
Linking Files
Overview

MODFLOW

SWATMODFLOW
Setting
up
Simulatio
n
RT3D

55

SWAT-MODFLOW-RT3D
Run Simulation
Overview

MODFLOW

SWATMODFLOW
Setting
up
Simulatio
n
RT3D

56

Setting up a Simulation
Running Simulation
Overview

1. SWAT Input Files


MODFLOW

2. MODFLOW Input Files


SWATMODFLOW
Setting
up
Simulatio
n
RT3D

modflow_LRW.dis, last line: change SS to TR

3. swatmf_link.txt
4. swatmf_ linkage files
5. SWAT_MODFLOW.exe

Run!
57

Setting up a Simulation
Viewing Results
Overview

MODFLOW

SWATMODFLOW

1. Spatially-variable recharge
2. Groundwater hydraulic head
3. Hydraulic head fluctuation
4. Groundwater discharge to stream network

Setting
up
Simulatio
n
RT3D

58

Setting up a Simulation
Viewing Results
Overview

MODFLOW

1.
2.
3.
4.

Spatially-variable recharge
Groundwater hydraulic head
Hydraulic head fluctuation
Groundwater discharge to stream network

swatmf_out_MF_recharge
SWATMODFLOW

m3/day (for each grid cell)

Setting
up
Simulatio
n
RT3D

59

Setting up a Simulation
Viewing Results
Overview

MODFLOW

1.
2.
3.
4.

Spatially-variable recharge
Groundwater hydraulic head
Hydraulic head fluctuation
Groundwater discharge to stream network

swatmf_out_MF_recharge
SWATMODFLOW
Setting
up
Simulatio
n
RT3D

60

Setting up a Simulation
Viewing Results
Overview

MODFLOW

SWATMODFLOW

1.
2.
3.
4.

Spatially-variable recharge
Groundwater hydraulic head
Hydraulic head fluctuation
Groundwater discharge to stream network

modflow.hed

Setting
up
Simulatio
n
RT3D

61

Setting up a Simulation
Viewing Results
Overview

MODFLOW

SWATMODFLOW
Setting
up
Simulatio
n
RT3D

1.
2.
3.
4.

Spatially-variable recharge
Groundwater hydraulic head
Hydraulic head fluctuation
Groundwater discharge to stream network
Depth to Water Table

modflow.hed
modflow.dis
Ground Surface Elevation
Hydraulic Head

62

Setting up a Simulation
Viewing Results
Overview

MODFLOW

SWATMODFLOW

1.
2.
3.
4.

Spatially-variable recharge
Groundwater hydraulic head
Hydraulic head fluctuation
Groundwater discharge to stream network

swatmf_out_MF_obs

Setting
up
Simulatio
n
RT3D

63

Setting up a Simulation
Viewing Results
Overview

MODFLOW

SWATMODFLOW

1.
2.
3.
4.

Spatially-variable recharge
Groundwater hydraulic head
Hydraulic head fluctuation
Groundwater discharge to stream network

swatmf_out_MF_obs

Setting
up
Simulatio
n
RT3D

64

Setting up a Simulation
Viewing Results
Overview

MODFLOW

SWATMODFLOW

1.
2.
3.
4.

Spatially-variable recharge
Groundwater hydraulic head
Hydraulic head fluctuation
Groundwater discharge to stream network

swatmf_out_MF_gwsw

Groundwater
Discharge
to Streams

Setting
up
Simulatio
n
RT3D

65

Outline of Workshop
1. Overview of SWAT-MODFLOW
2. Details of MODFLOW
3. Details of SWAT-MODFLOW
4. Setting up a SWAT-MODFLOW Model
5. Groundwater Contaminant Transport using
66
RT3D

SWAT-MODFLOW-RT3D
RT3D Introduction
Overview

Reactive Transport in 3 Dimensions

MODFLOW

SWATMODFLOW
Setting up
Simulation
RT3D

Dispersion Advection

Reactions
(first-order kinetics)

Sources and Sinks


67

SWAT-MODFLOW-RT3D
RT3D Introduction
Overview

Reactive Transport in 3 Dimensions

MODFLOW

SWATMODFLOW
Setting up
Simulation
RT3D

Finite Difference Method


Same grid as MODFLOW
Flows/SS from MODFLOW
68

SWAT-MODFLOW-RT3D
Overview

Linking 3 Models:
SWAT
Soil percolation
Potential ET not satisfied
River Stage
Pumping required

MODFLOW

SWATMODFLOW
Setting up
Simulation
RT3D

N, P in percolating water
N, P in stream water

RT3D

MODFLOW
Water Table height
GW/SW Interaction
Groundwater flows, sources/sinks

N, P concentrations in vadose zone


Mass of N, P to/from Surface Water
N, P concentrations in saturated zone

69

SWAT-MODFLOW-RT3D
Code Structure
Overview

MODFLOW

SWATMODFLOW

Read/Allocate MODFLOW / RT3D


simulate
Years
Days
command
1: subbasin (hru calculations)
19: MODFLOW / RT3D

Setting up
Simulation

Map SWAT Grid


HRU values disaggregated HRUs (DHRUs)
DHRUs Grid cells
River stage MODFLOW River cells

RT3D

Run MODFLOW
Run RT3D Denitrification
Map Grid SWAT
GW Discharge Subbasin streams
NO3 loading Subbasin streams

2: Route

70

NO3 in percolation
NO3 in river water

SWAT-MODFLOW-RT3D
Example Simulations (Klamath Basin)
Overview

MODFLOW

Simulation Results
Nitrate Concentration in Groundwater

SWATMODFLOW
Setting up
Simulation
RT3D

71

SWAT-MODFLOW-RT3D
Example Simulations (Klamath Basin)
Overview

MODFLOW

Simulation Results
Groundwater Nitrate Loading to Streams

SWATMODFLOW
Setting up
Simulation
RT3D

72

SWAT-MODFLOW-RT3D
RT3D Files
Overview

MODFLOW

Advection
Dispersion

SWATMODFLOW
Setting up
Simulation

Reactions
Source/Sin
k

RT3D

73

SWAT-MODFLOW-RT3D
Run Simulation
Overview

MODFLOW

SWATMODFLOW
Setting up
Simulation
RT3D

74

SWAT-MODFLOW-RT3D
Running Simulation
Overview

1. SWAT Input Files

MODFLOW

2. MODFLOW Input Files

SWATMODFLOW
Setting up
Simulation
RT3D

modflow_LRW.dis, last line: change SS to TR

3. swatmf_link.txt
4. swatmf_ linkage files
5. SWAT_MODFLOW.exe
6. RT3D Input Files (and folder)
7. swatmf_link.txt: set rt_active to 1
Run!

SWAT-MODFLOW-RT3D
Viewing Results
Overview

1. Groundwater NO3 Concentration


2. Groundwater NO3 loading to streams

MODFLOW

SWATMODFLOW

rt3d_no3grid

Setting up
Simulation
RT3D

76

SWAT-MODFLOW-RT3D
Viewing Results
Overview

1. Groundwater NO3 Concentration


2. Groundwater NO3 loading to streams

MODFLOW

SWATMODFLOW

grams of NO3-N
Ssmass_no3

Leaving Aquifer

Setting up
Simulation
RT3D

77

Thank you for your Participation!

78

You might also like