support {Calculator.LR.FNs} R Documentation

## Support of LR fuzzy number

### Description

To determining the support of a LR fuzzy number one can use from this function. In other words, the support function is able to compute the smallest and biggest values x for which \mu(x)>0.

### Usage

support(M, Left.fun = NULL, Right.fun = NULL)


### Arguments

 M A LR, RL or L fuzzy number Left.fun The left-shape function which usually defined before using LRFN.plot (see examples in bellow) Right.fun The right-shape function which usually defined before using LRFN.plot (see examples in bellow)

### Value

The "support" function return a interval-valued vector in which the membership function value of LR fuzzy number is bigger than zero.

Abbas Parchami

### Examples

Left.fun  = function(x)  { (1-x)*(x>=0)}
Right.fun = function(x)  { (exp(-x))*(x>=0)}
T = LR(1, 0.6, 0.2)
support(T)
LRFN.plot( T, xlim=c(-5,20), lwd=2, lty=3, col=4)

N = RL(3, 0.5, 2)
support(N)

Left.fun  = function(x)  { (1-x)*(x>=0)}
M = L(2,4,3)
support(M)

Left.fun  = function(x)  { (1-x^2)*(x>=0)}
Right.fun = function(x)  { (exp(-x))*(x>=0)}
support( LR(17,5,3))

## The function is currently defined as
function (M, Left.fun = NULL, Right.fun = NULL)
{
range1 = M - M - M - 100
range2 = M + M + M + 100
x = seq(range1, range2, len = 2e+05)
if (M == 0) {
y = Left.fun((M - x)/M) * (x <= M) + Right.fun((x -
M)/M) * (M < x)
}
else if (M == 1) {
y = Right.fun((M - x)/M) * (x <= M) + Left.fun((x -
M)/M) * (M < x)
}
else if (M == 0.5) {
y = Left.fun((M - x)/M) * (x <= M) + Left.fun((x -
M)/M) * (M < x)
}
supp = c()
supp = min(x[0 < y & y < 1])
supp = max(x[0 < y & y < 1])
if (supp == min(x)) {
supp = -Inf
}
if (supp == max(x)) {
supp = +Inf
}
return(supp)

}


[Package Calculator.LR.FNs version 1.3 Index]