Skip to content


Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Soil-Water-Balance: A Modified Thornthwaite-Mather Soil-Water-Balance Code for Estimating Groundwater Recharge
HTML FORTRAN C R CMake Shell Other
branch: master

FEATURE: allow access to the parameters controlling the growing seaso…

…n switch when using the GDD option.

New directives are:


When the GROWING_SEASON GDD directive is specified, the two numbers given above will be used to determine the approximate start and end of the growing season. For each cell, a growing season specific GDD is calculated. The growing season begins when this GDD exceeds the GROWING_SEASON_STARTING_GDD. The growing season ends when the daily minimum air temperature falls beneath the GROWING_SEASON_KILLING_FROST. It is possible for the growing season to "toggle" several times between growing and nongrowing if there are wide temperature swings in the spring.
latest commit 81a5612309
@smwesten-usgs authored
Failed to load latest commit information.
build Add updated makefile for Mac.
dist Placing the example files, readme.txt, etc. under Git version control
doc Add markdown files describing projections and output variable descrip…
include Update dislin.mod file to gfortran 4.90
lib Update library files; x86 libraries do *NOT* support OpenDAP/THREDDs …
presentations Remove pLanduse from config and model modules.
test_case Add flag to suppress floating point exceptions following Fortran stop…
tests ISSUE: land use that reverts from irrigated to unirrigated causes SWB…
webpages Experiment with changes to Doxygen
.gitignore Update gitignore
CMakeLists.txt Update expected CMake version and pathnames.
Doxyfile Experiment with changes to Doxygen
Doxyfile.mac_osx Update new interception modules; fix Doxygen problem with module data… Updated

SWB - A Modified Thornthwaite-Mather Soil-Water-Balance Code for Estimating Groundwater Recharge

NOTICE: This is the public GitHub repository for the USGS Soil-Water-Balance model. Code found here is under development and may not be suitable for important project work. The official version of the code may be found at:

The Soil-Water-Balance (SWB) computer code has been developed to calculate spatial and temporal variations in groundwater recharge. The SWB model calculates recharge by use of commonly available geographic information system (GIS) data layers in combination with tabular climatological data. The code is based on a modified Thornthwaite-Mather soil-water-balance approach, with components of the soil-water balance calculated at a daily timestep. Recharge calculations are made on a rectangular grid of computational elements that may be easily imported into a regional groundwater-flow model. Recharge estimates calculated by the code may be output as daily, monthly, or annual values.

Software User Rights Notice

Software and related material (data and (or) documentation), contained in or furnished in connection with a software distribution, are made available by the U.S. Geological Survey (USGS) to be used in the public interest and in the advancement of science. You may, without any fee or cost, use, copy, modify, or distribute this software, and any derivative works thereof, and its supporting documentation, subject to the following restrictions and understandings.

If you distribute copies or modifications of the software and related material, make sure the recipients receive a copy of this notice and receive or can get a copy of the original distribution. If the software and (or) related material are modified and distributed, it must be made clear that the recipients do not have the original and they must be informed of the extent of the modifications. For example, modified files must include a prominent notice stating the modifications made, the author of the modifications, and the date the modifications were made. This restriction is necessary to guard against problems introduced in the software by others, reflecting negatively on the reputation of the USGS.

The software is public property and you therefore have the right to the source code, if desired.

You may charge fees for distribution, warranties, and services provided in connection with the software or derivative works thereof. The name USGS can be used in any advertising or publicity to endorse or promote any products or commercial entity using this software if specific written permission is obtained from the USGS.

The user agrees to appropriately acknowledge the authors and the USGS in publications that result from the use of this software or in products that include this software in whole or in part.

Because the software and related material are free (other than nominal materials and handling fees) and provided "as is," the authors, the USGS, and the United States Government have made no warranty, express or implied, as to accuracy or completeness and are not obligated to provide the user with any support, consulting, training or assistance of any kind with regard to the use, operation, and performance of this software nor to provide the user with any updates, revisions, new versions or "bug fixes".

The user assumes all risk for any damages whatsoever resulting from loss of use, data, or profits arising in connection with the access, use, quality, or performance of this software.

Something went wrong with that request. Please try again.