Calculate distances and angles for a turbine and all it's potentially influencing turbines.
get_dist_angles(t, o, wnkl, dist, polYgon, plotAngles = FALSE)
A data.frame of the current individual with X and Y coordinates
A numeric value indicating the index of the current turbine
The angle from which wake influences are considered to be negligible
A numeric value indicating the distance, after which the wake effects are considered to be eliminated.
A shapefile representing the considered area
A logical variable, which is used to plot the distances and
angles. Default is FALSE
Returns a matrix with the distances and angles of potentially influencing turbines
Other Wind Energy Calculation Functions:
barometric_height()
,
calculate_energy()
,
turbine_influences()
# NOT RUN {
library(sf)
## Exemplary input Polygon with 2km x 2km:
Polygon1 <- sf::st_as_sf(sf::st_sfc(
sf::st_polygon(list(cbind(
c(4498482, 4498482, 4499991, 4499991, 4498482),
c(2668272, 2669343, 2669343, 2668272, 2668272)))),
crs = 3035
))
## Create a random windfarm with 10 turbines
t <- st_coordinates(st_sample(Polygon1, 10))
wnkl <- 20
dist <- 100000
## Evaluate and plot for every turbine all other potentially influencing turbines
potInfTur <- list()
for (i in 1:(length(t[,1]))) {
potInfTur[[i]] <- get_dist_angles(t = t, o = i, wnkl = wnkl,
dist = dist, polYgon = Polygon1, plotAngles = TRUE)
}
potInfTur
# }
Run the code above in your browser using DataLab