Skip to contents

Package Documentation

windfarmGA_
windfarmGA

Run an Optimization

genetic_algorithm()
Run a Genetic Algorithm to optimize a wind farm layout
windfarmGA()
Run a Genetic Algorithm to optimize a wind farm layout

Genetic Algorithm Components

Main components of the genetic algorithm

init_population()
Create a random initial Population
selection()
Selection Method
fitness()
Evaluate the Individual Fitness values
crossover()
Crossover Method
mutation()
Mutation Method
trimton()
Adjust the amount of turbines per windfarm

Wind Energy Calculation Functions

barometric_height()
Calculates Air Density, Air Pressure and Temperature according to the Barometric Height Formula
get_dist_angles()
Calculate distances and angles of possibly influencing turbines
turbine_influences()
Find potentially influencing turbines
calculate_energy()
Calculate Energy Outputs of Individuals

Randomization

random_search()
Randomize the output of the Genetic Algorithm
random_search_single()
Randomize the location of a single turbine
plot_random_search()
Plot the result of a randomized output.

Plotting Functions

plot_cloud()
Plot outputs of all generations with standard deviations
plot_development()
Plot the progress of populations
plot_evolution()
Plot the evolution of fitness values
plot_fitness_evolution()
Plot the changes of min/mean/max fitness values
plot_heatmap()
Plot a heatmap of selected grid cells
plot_leaflet()
Plot a wind warm with leaflet
plot_parkfitness()
Plot the genetic algorithm results
plot_random_search()
Plot the result of a randomized output.
plot_result()
Plot the best results
plot_viewshed()
Plot viewshed results
plot_windfarmGA()
Plot the results of an optimization run
plot_windrose()
Plot a Windrose
interpol_view()
Plot an interpolated viewshed

Viewshed Analysis Functions

cansee()
Calculate Visibility between 2 locations
rasterprofile()
Sample values from a raster
viewshed()
Calculate visibility
viewTo()
Calculate Visibility between multiple locations
interpol_view()
Plot an interpolated viewshed
plot_viewshed()
Plot viewshed results

Helper Functions

get_grids()
Get the Grid-IDs from binary matrix
grid_area()
Make a grid from a Simple Feature Polygon
hexa_area()
Polygon to Hexagonal Grids
windata_format()
Transform Winddata
isSpatial()
Transform to Simple Feature Polygons
permutations()
Enumerate the Combinations or Permutations of the Elements of a Vector
readinteger()
Check Input Crossover Method
readintegerSel()
Check Input Selection Method
splitAt()
Split matrices or numeric vectors at specific indices
dup_coords()
Splits duplicated coords (copy of geoR::dup.coords)
getDEM()
Get DEM raster
getISO3()
getISO3

Datasets

Results and Shapefiles included in the package.

resultrect
A resulting matrix of genetic_algorithm with 200 iterations and a rectangular grid derived from sp_polygon
resulthex
A resulting matrix of genetic_algorithm with 10 iterations and a hexagonal grid derived from sp_polygon
sp_polygon
The rectangular POLYGON used to create resultrect & resulthex
big_shape
A POLYGON with an area of ~70 km2
hole_shape
A POLYGON with a hole
multi_shape
A MULTIPOLYGON with 3 Polygons