# problemdata: Claims problem data In ClaimsProblems: Analysis of Conflicting Claims

## Description

The function returns to which of the following sub-domains the claims problem belongs to: the lower-half, higher-half, and midpoint domains. In addittion, the function returns the minimal rights vector, the truncated claims vector, the sum and the half-sum of claims.

## Usage

 `1` ```problemdata(E, d, draw = FALSE) ```

## Arguments

 `E` The endowment. `d` The vector of claims. `draw` A logical value.

## Details

Let E≥ 0 be the endowment to be divided and d the vector of claims with d≥ 0 and such that D=∑ di ≥ E, the sum of claims D exceeds the endowment.

The lower-half domain is the sub-domain of claims problems for which the endowment is less or equal than the half-sum of claims, E ≤ D/2.

The higher-half domain is the sub-domain of claims problems for which the endowment is greater or equal than the half-sum of claims, E ≥ D/2.

The midpoint domain is the sub-domain of claims problems for which the endowment is equal to the half-sum of claims, E = D/2.

The minimal right of claimant i in (E,d) is whatever is left after every other claimant has received his claim, or 0 if that is not possible:

mi = max{ 0 , E-d(N-{i}) }, i=1,…,n.

Let m(E,d)=(m1,…,mn) be the vector of minimal rights.

The truncated claim of claimant i in (E,d) is the minimum of the claim and the endowment:

ti = min{di,E}, i=1,…,n.

Let t(E,d)=(t1,…,tn) be the vector of truncated claims.

## Value

The minimal rights vector; the truncated claims vector; the sum, the half-sum of the claims, and the class (lower-half, higher-half, and midpoint domains) to which the claims problem belongs. It returns cod = 1 if the claims problem belong to the lower-half domain, cod = -1 if it belongs to the higher-half domain, and cod = 0 for the midpoint domain. Moreover, if draw = TRUE a plot of the claims, from small to large in the interval [0,D], is given.

 ```1 2 3``` ```E=10 d=c(2,4,7,8) problemdata(E,d,draw=TRUE) ```