isinthecore: Isinthecore (core allocations)

Description Usage Arguments Author(s) References Examples

Description

This function checks if the allocation belongs to the core of the TU game.

Usage

1
isinthecore(characteristic_function, allocation, game = c("profit", "cost"))

Arguments

characteristic_function

A vector with the characteristic function v(S) (or c(S), if we work with a cost game), according to the order of coalitions shown in coalitions function.

allocation

A vector with the allocation where each component indicates the part of each agent.

game

Characters to indicate if the game is a cost or profit game. The possibles values are "cost" or "profit".

Author(s)

A. Saavedra-Nieves

References

Gillies, D.B. (1953). Some theorems on n-person games. PhD thesis, Princeton University.

Examples

1
2
3
4
5
6
7
8
characteristic_function<-c(0,0.538, 0.761, 1.742, 0.554, 0.137, 0.293, 0.343)
isinthecore(characteristic_function,allocation=c(0.1,0.2,0.043),game="cost")
#[1] "The allocation is not in the core"
#NULL

isinthecore(characteristic_function,allocation=c(0.05,0.206,0.087),game="cost")
#[1] "The allocation is in the core"
#NULL

Example output

Loading required package: e1071
Loading required package: lpSolveAPI
[1] "The allocation is not in the core"
NULL
[1] "The allocation is in the core"
NULL

GameTheoryAllocation documentation built on May 6, 2019, 1:10 a.m.