- #1

- 4

- 0

chromosome = initialize_variables(pop,pro);

What is the meaning of this line ?

Thank you..

What is the meaning of this line ?

Thank you..

- MATLAB
- Thread starter yeongchuan88
- Start date

- #1

- 4

- 0

chromosome = initialize_variables(pop,pro);

What is the meaning of this line ?

Thank you..

What is the meaning of this line ?

Thank you..

- #2

- 245

- 0

initialize_variables could be a user defined function which takes pop and pro as inputs and chromosome is the output of the function.

Type "help initialize_variables" in matlab command prompt to know about that function.

- #3

- 4

- 0

What is the difference between

function f = initialize_variables(N,problem)

and

function [f] = initialize_variables(N,problem)

Thank you !

function f = initialize_variables(N,problem)

and

function [f] = initialize_variables(N,problem)

Thank you !

Last edited:

- #4

- 245

- 0

No difference.What is the difference between

function f = initialize_variables(N,problem)

and

function [f] = initialize_variables(N,problem)

Thank you !

If two output variables are there (say f and g)then

function [f,g] = initialize_variables(N,problem)

For single variable it wont make difference.

- Last Post

- Replies
- 5

- Views
- 3K

- Last Post

- Replies
- 2

- Views
- 9K

- Last Post

- Replies
- 2

- Views
- 3K

- Last Post

- Replies
- 4

- Views
- 645

- Last Post

- Replies
- 1

- Views
- 2K

- Last Post

- Replies
- 13

- Views
- 11K

- Last Post

- Replies
- 1

- Views
- 3K

- Last Post

- Replies
- 2

- Views
- 4K

- Last Post

- Replies
- 3

- Views
- 3K

- Last Post

- Replies
- 6

- Views
- 3K