evalDomainVolume: Evaluate the volume of a polyhedron

View source: R/getIntersectionLinesHyperplanes.R

evalDomainVolumeR Documentation

Evaluate the volume of a polyhedron

Description

This function returns the volume of a polyhedron by calling the function evalInter in order to find the shared volume between this polyhedron and a standard polyhedron which dimension is known.

Usage

evalDomainVolume(
  A,
  nbPoints = 50000,
  seed = 123456,
  assessment_range = c(-15000, 15000),
  direction = NULL
)

Arguments

A

data.table, polyhedron which volume is to be evaluated, data.table containing at least two ptdf columns :

  • ptdfAT : autrichian vertices

  • ptdfBE : belgium vertices

  • ptdfDE : german vertices

  • ptdfFR : french vertices

nbPoints

numeric, number of points generated

seed

numeric fixed random seed, used for the weighted draw of the points. By default, the value is 123456

assessment_range

The range in which the points for the volume assessment should be drawn. This range should cover the entire domain described by A

direction

data.table used to provide specific directions in which the volume calculation should be performed. The data table must contain two columns:

  • a column "country" containing the names of the countries on which a direction is specified

  • a column "direction" containing a string which can be either "positive" to specify that only positive net positions must be considered for this country, or "negative" if only negative net positions must be considered

Value

The volume of polyhedron A

Examples

## Not run: 
library(data.table)
polyhedra <- readRDS(system.file("testdata/polyhedra.rds", package = "fbAntares"))
A <- polyhedra[Date == "2019-02-14"]
nbPoints <- 50000

 evalDomainVolume(A = A, nbPoints = nbPoints)

## End(Not run)


rte-antares-rpackage/fbAntares documentation built on June 1, 2022, 6:20 p.m.