Discover MakerZone

MATLAB and Simulink resources for Arduino, LEGO, and Raspberry Pi

Learn more

Discover what MATLAB® can do for your career.

Opportunities for recent engineering grads.

Apply Today

Thread Subject:
how to define my GA optimization problem only once ? and how to display more variables ?

Subject: how to define my GA optimization problem only once ? and how to display more variables ?

From: Mamdouh

Date: 22 Jan, 2014 01:26:09

Message: 1 of 1

Hello,
I have some integer variables, so I almost forced to use GA although I have nonlinear constrains, three objective functions, and many hundreds of variables ...
anyway
I combined the three objective functions in one objective function by multiplying each one by a certain weighting parameter ranging from 0 to 1.0
I built up my code in one .m file (containing the fitness function, the constrain function, and the GA function)
my two questions are:
1- I repeated the problem settings and constants in all these three functions, so my code became long, how can I define them only once ?
2- I wanna know the final value of all the three objective functions as well as some other variables in order to compare results, how can I do that ?

I am not sure if my thread is clear enough,
if you wanna help and couldn't follow my thread, kindly ask me for clarification,
thanks in advance,
Kind Regards
Mamdouh

Tags for this Thread

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Contact us