diff --git a/matlab/tests/private/testcu.m b/matlab/tests/private/testcu.m index 2d68232ea6..31788e04df 100644 --- a/matlab/tests/private/testcu.m +++ b/matlab/tests/private/testcu.m @@ -815,7 +815,8 @@ case {'absolute', 'additive', 'add', 'a', '+'} f = f + noise.level*r; otherwise - f = f * (1 + noise.level*r); + %f = f * (1 + noise.level*r); + f = f + max(abs(f), 1)*noise.level*r; % abs(f) is reasonable because the distribution of r is symmetric w.r.t. 0. end end end @@ -829,7 +830,8 @@ case {'absolute', 'additive', 'add', 'a', '+'} f = f + dnoise.level*r; otherwise - f = f * (1 + dnoise.level*r); + %f = f * (1 + dnoise.level*r); + f = f + max(abs(f), 1)*dnoise.level*r; end end end @@ -1063,7 +1065,7 @@ 'OET6', ... 'OET7', ... 'QINGNE', ... - 'QPCBLEND' , ... + 'QPCBLEND', ... 'SPANHYD', ... % 15 'SWOPF', ... % 10 'TAX13322', ... % 5 diff --git a/matlab/tests/profile.m b/matlab/tests/profile.m index 6d4edc1ecb..b940e54706 100644 --- a/matlab/tests/profile.m +++ b/matlab/tests/profile.m @@ -91,7 +91,7 @@ if isfield(options, 'eval_options') && isstruct(options.eval_options) && ~isempty(fieldnames(options.eval_options)) test_feature = [test_feature, '.', strjoin(fieldnames(options.eval_options), '_')]; if isfield(options.eval_options, 'dnoise') - if isnumeric(options.eval_options.dnoise) && isscalar(options.eval_options) + if isnumeric(options.eval_options.dnoise) && isscalar(options.eval_options.dnoise) dnoise_level = abs(options.eval_options.dnoise); elseif isstruct(options.eval_options.dnoise) && isfield(options.eval_options.dnoise, 'level') dnoise_level = abs(options.eval_options.dnoise.level); @@ -103,7 +103,7 @@ end end if isfield(options.eval_options, 'noise') - if isnumeric(options.eval_options.noise) && isscalar(options.eval_options) + if isnumeric(options.eval_options.noise) && isscalar(options.eval_options.noise) noise_level = abs(options.eval_options.noise); elseif isstruct(options.eval_options.noise) && isfield(options.eval_options.noise, 'level') noise_level = abs(options.eval_options.noise.level);