# Ant colony optimization algorithm

if i have an equation like $$f_n = x + y + z + a + b$$ and each variable has a discrete answer like $a = 0, 1 , 3$ . $b = 2 ,4,5$ etc. i want to find the global optimum minimization point. I used Ant colony optimization (ACO) to solve the equation but i am stuck in the heuristic information and how to compute these parameters, as I saw in the traveling sale's man problem eta = one over distance between two cities. But here there is no relation between $x$ and $y$ .

Second i want to make sure that when computing $\delta_\tau$ pheromone updating trail , its equal to $$f_n(\text{best answer in iteration k})\over f_n(\text{worth answer in iteration k})$$ as i saw another equations in papers and got distracted. I built a matlab model but it didn't give me the optimum point at each run time . Thank you

• 1) Why ACO? 2) It's not clear to me what exactly you are stuck on. 3) A heuristic will not give you the correct answer every time. That's inherent. If you can't tolerate errors, you need to use other methods. – Raphael Jul 21 '17 at 7:45
• I used ACO to find the shortest path as the equation above is just an example but in reality the equation has 100 variable and could be more depending on the loads connected. The problem i face is that i need to figure out the correct parameters that i have to use. and to make sure that the second equation is true . Please, if you have a recommended material to guide me , mention it. @Raphael – Rehab_Hsn Jul 21 '17 at 8:40
• For shortest paths, use standard algorithms. As for ACO, I guess the same is true as for any heuristic/stochastic optimization method: there's no cookbook. Fiddle around until it works well on your test instances, and hope that the same parameterization will "succeed" on the real instances as well. – Raphael Jul 21 '17 at 15:08
• What exactly is the problem you are trying to solve? You talk about minimization; but what quantity are you trying to minimize? Later you talk about solving the equation, but what do you mean by that? I don't see how to reconcile those two statements. Also what does your notation $a=0,1,3$ mean? Do you mean that $a$ is only allowed to take on the value 0, 1, or 3? When you write "its equal", what does "its" refer to? – D.W. Jul 21 '17 at 20:53
• yes i am trying to minimize the value of $fn$ and its function of x ,y ,z ,a and b. and each of those variable could have a possible answer and you have to choose among this vales. So , yes , a is allowed to take the value 0 , 1, or 3 but you have to choose the value that makes the fn minim. @D.W. – Rehab_Hsn Jul 21 '17 at 21:01

2. Grid search: Systematically search over the space of possible parameters. For instance, if there are two parameters $\alpha$ and $\beta$, you might let $\alpha$ range over values $0.1$, $1$, $10$, and $100$, and let \$\beta range over a similar set, and try all combinations; then take the best solution found.