# Particle swarm optimization for root

**URL:** <https://root-forum.cern.ch/t/particle-swarm-optimization-for-root/13783>\
**Category:** Evolution Proposals, Apps & Ideas\
**Created:** [February 13, 2012, 10:52pm UTC](https://root-forum.cern.ch/t/particle-swarm-optimization-for-root/13783 "2012-02-13T22:52:35Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![dawehner](https://root-forum.cern.ch/user_avatar/root-forum.cern.ch/dawehner/32/11773_2.png) [@dawehner](https://root-forum.cern.ch/u/dawehner)\
**Post date:** [February 13, 2012, 10:52pm UTC](https://root-forum.cern.ch/t/particle-swarm-optimization-for-root/13783/1 "2012-02-13T22:52:35Z")

</div>

ROOT does already have support for genetic algorithms so i was wondering why there is no support for particle swarm optimization [1] yet. Maybe someone else already wrote some software for ROOT though i couldn’t find one yet.

This is just a start to get some feedback. You could either compile example.cpp or run ith with

```auto
.x example.cpp+
```

The folder has an output folder with a video which shows how the particles find the best place.

It implements two problems which aren’t that easy to solve with classical optimizer.

Any kind of feedback is asked for.

[1] [engr.iupui.edu/~shi/Coference/psopap4.html](http://www.engr.iupui.edu/~shi/Coference/psopap4.html)  
[output.tar.gz](https://root-forum.cern.ch/uploads/default/original/2X/a/a3e591c82be37bcf26262d1cb17a0c064e9f1e68.gz) (1.12 MB)
