UQLab Reliability Results Incorrect sign of Beta

Dear All,
I am solving a simple problem in UQLab Reliability, but I am getting incorrect sign of the reliability Index Beta while the Pf is correct, when using FORM, SORM, MCS. But correct results when using IS, and AK-MCS. I am attaching the Problem (From Ang and Tang) and the UqLab file. Any comments appreciated.


ModelOpts.mString = '144./(2.*X(:,1))+X(:,2)-12.*X(:,3)-144./(2.*X(:,4))';
ModelOpts.isVectorized = true;
myModel = uq_createModel(ModelOpts);
InputOpts.Marginals(1).Name = 'X1';  % resistance variable
InputOpts.Marginals(1).Type = 'Gaussian';
InputOpts.Marginals(1).Moments = [2 0.1*2];
InputOpts.Marginals(2).Name = 'X2';  % resistance variable
InputOpts.Marginals(2).Type = 'Gamma';
InputOpts.Marginals(2).Moments = [60 0.8*60];
InputOpts.Marginals(3).Name = 'X3';  % stress variable
InputOpts.Marginals(3).Type = 'Gaussian';
InputOpts.Marginals(3).Moments = [0.9 0.3];
InputOpts.Marginals(4).Name = 'X4';  % stress variable
InputOpts.Marginals(4).Type = 'Gaussian';
InputOpts.Marginals(4).Moments = [0.5 0.05*0.5];
myInput = uq_createInput(InputOpts);
FORMOpts.Type = 'Reliability';
FORMOpts.Method = 'FORM';
FORMAnalysis = uq_createAnalysis(FORMOpts);

Pf 8.8590e-01
BetaHL 1.2050
ModelEvaluations 18

Variables X1 X2 X3 X4
Ustar -0.090505 1.185504 -0.088913 0.174698
Xstar 1.98e+00 1.17e+02 8.73e-01 5.04e-01
Importance 0.005641 0.967896 0.005444 0.021018


Pf 8.8667e-01
Beta -1.2090
CoV 0.0011
ModelEvaluations 151
PfCI [8.8471e-01 8.8863e-01]
BetaCI [-1.2193e+00 -1.1988e+00]
PfMinus/Plus [8.8667e-01 8.8667e-01]

Hi @sbarakat,

Thanks for reporting the issue. The \beta calculated by UQLab for the methods “MCS”, “IS”, “FORM”, and “SORM” is always positive (it is set to its absolute value). This is indeed a bug, and we will fix it in the next release. Nevertheless, this bug affects only the sign of \beta, and all the other quantities, including the failure probability, are correct.