Parallelization of a Genetic Algorithm (not from the toolbox)

1 view (last 30 days)
I'm writing a parallel Genetic Algorithm in Matlab, specifically a Dual Species Genetic Algorithm (DSGA) (more information can be found in this paper here ), and I'm having some trouble parallelizing part of the code.
Now I'm a physics and math major and I'm just getting started with my programming to help with my research projects. I've already implemented a serial genetic algorithm in Matlab with a somewhat parallelized fitness function, but I'm interested in implementing this Dual Species Genetic Algorithm.
Okay so the question: how can i run 2 different for loops that are doing different things on different matlab workers? The 2 for loops will have different data and different code, but I need them to be running simultaneously. I don't think i could use a parfor loop for that. After reading through the documentation for the parallel tool box it looks like using the Single Program Multiple Data (spmd) function may be an option? I'm not really sure if its the best option of it would really work at all.
Any advice would be appreciated.
Thanks.

Answers (0)

Community Treasure Hunt

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

Start Hunting!