Vous suivez désormais cette soumission
- Les mises à jour seront visibles dans votre flux de contenu suivi
- Selon vos préférences en matière de communication il est possible que vous receviez des e-mails
EACH INDIVIDUAL:- [1*8] where each column value tells the position of queen in that particular column
FINAL SOLUTION:- each row gives one unique solution in the 'solution' matrix
It has very basic but effective functions of selection,crossover and mutation.
Queens are randomly positioned in the beginning.
I have written it for n-queens.
It gives a good amount of solutions for queens > 8.
Also you can change parameters and test for yourself.
The cross-over logic is given in the attached PDF-cross-over_logic.
Citation pour cette source
Swapnil Marathe (2026). Genetic Algorithm for n-queen problem (https://fr.mathworks.com/matlabcentral/fileexchange/35820-genetic-algorithm-for-n-queen-problem), MATLAB Central File Exchange. Extrait(e) le .
Remerciements
Inspiré par : Travelling salesman problem with Genetic algorithm
Informations générales
- Version 1.3.0.0 (5,42 ko)
Compatibilité avec les versions de MATLAB
- Compatible avec toutes les versions
Plateformes compatibles
- Windows
- macOS
- Linux
| Version | Publié le | Notes de version | Action |
|---|---|---|---|
| 1.3.0.0 | Modified the file to calculate the fitness function for 'n' queens and not 8 queens |
||
| 1.1.0.0 | description of how the each individual has been defined |
||
| 1.0.0.0 |
