get_single_drawdown_relationship: Get drawdown relationship

Description Usage Arguments Value Examples

View source: R/anem_wrappers.R

Description

Get drawdown relationship at locations locations due to unit pumping from wells. Include weights on location and wells.

Usage

1
2
get_single_drawdown_relationship(wells, aquifer, group_column,
  weights_column, loc_group, pump_group)

Arguments

wells

Wells data.frame or tibble

aquifer

Aquifer object

group_column

Name of column to identify groups of wells (no quotes)

weights_column

Name of column to identify weights of well pumping (no quotes). Required – create column equal to 1 if equal weights desired.

loc_group

Value in wells$group_column where drawdown should be measured

pump_group

Value in wells$group_column which identifies wells

Value

Returns a list with two values: pot, which is the potential differential due to unit pumping from the pumping wells in pump_group.

var, which is given as D_i_j, or PHI_i_j – the average drawdown at wells i due to wells j.

The unit pumping at the pumping wells is weighted by values in weights_column for the pump_group. The average drawdown is also weighted by values in weights_column, for the loc_group.

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
## Not run: 
# define aquifer
bounds_df <- data.frame(bound_type=c("CH","NF","NF","NF"),
  m=c(Inf,0,Inf,0),b=c(0,1000,1000,0))
aquifer_unconfined <- define_aquifer("unconfined",1e-3,bounds=bounds_df,h0=100)

# define wells and well images
library(dplyr)
set.seed(30)
wells_df <- data.frame(x=runif(8,0,1000),y=runif(8,0,1000),diam=1,R=1000) %>%
  mutate(country=factor(y>500,levels=c(FALSE,TRUE),labels=c("A","B"))) %>%
  group_by(country) %>%
  mutate(weights=1,Q=1/n()) %>% group_by()
wells <- define_wells(wells_df) %>% generate_image_wells(aquifer_unconfined)

get_single_drawdown_relationship(wells, aquifer_unconfined,
  group_column=country, weights_column=weights,loc_group="S", pump_group="F")

library(ggplot2)
ggplot() +
  geom_segment(data=aquifer_unconfined$bounds,
    aes(x1,y1,xend=x2,yend=y2,color=bound_type)) +
  geom_abline(slope=0,intercept=500,linetype="dashed") +
  geom_point(data=wells %>% filter(wID==orig_wID),
    aes(x,y,fill=country),shape=21) +
  coord_equal()

## End(Not run)

gopalpenny/anem documentation built on Dec. 20, 2020, 5:27 a.m.