Limit the number of decimals in x variable paretosearch

1 Ansicht (letzte 30 Tage)
Pascual Ferrans Ramírez
Pascual Ferrans Ramírez am 8 Jun. 2022
Beantwortet: SAI SRUJAN am 1 Nov. 2023
Hi dear community,
I am currently working with a multiobjective optimization problem, involving 2 objective variables and multiple (250) X variables. I am using paretosearch. I want to limit to 0 the number of decimal digits that my X variables values may have (actually, I just want it to select between 0 and 1). Is there any way to do this from the options in paretosearch?
Thanks

Antworten (1)

SAI SRUJAN
SAI SRUJAN am 1 Nov. 2023
Hi Pascual Ferrans Ramirez,
I understand that you are trying to limit the number of decimals in "x" variable returned by "paretosearch".
To address the issue, normalize the Pareto points and subsequently map them to discrete values of either 0 or 1.
You can follow the given example to proceed further.
% pareto search returns pareto points as one amongst the outputs.
% Let us consider 'x' as pareto points.
X=[0.1 0.2 0.4 0.6]
% normalize or Scale the pareto points
scaled_X = (X-min(X))/(max(X)-min(X))
% Round pareto points to either 0 or 1.
rounded_X = round(scaled_X, 0)
You can refer to the following documentation to understand more about "paretosearch" MATLAB function.

Kategorien

Mehr zu Multiobjective Optimization finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by