Artificial Bee Colony Algorithm
Artificial Bee Colony Algorithm
Colony Algorithm
The Artificial Bee Colony (ABC) algorithm is an
optimization technique inspired by the foraging behavior
of honey bees. It was proposed by Dervis Karaboga in
2005.
Algorithm Steps:
Initialization: Generate initial food sources randomly.
Employed Bee Phase: Each employed bee visits a food source, evaluates its quality, and shares
this information.
Onlooker Bee Phase: Onlookers select food sources based on the information from employed
bees and further explore them.
Scout Bee Phase: Scouts search for new food sources to replace abandoned ones.
Cycle Repeat: The process repeats until a termination criterion is met (e.g., a maximum number
of cycles)
. ym
lodnar secruos doof lai t ini etarene
G
n:
oi tazi lai tinI :1petS
Decision variables:
● Fix the swarm size (S=6), Number of cycles (N=10) and Limit = 1
● Determine the no. of employed bees, onlooker bees and food sources.
Employed bees = Onlooker bees = Food sources =
● Generate random solutions using:
where are bound of in direction.
● Evaluate objective function value and fitness of population:
Fitness of population is calculated using:
Then,
Similarly we calculate all the objective function values and fitness of populations.
● Generate initial trail vector for population:
→ Every solution is associated with a variable called “trail” and its initial value is always 0.
→ If the value of trail is greater than limit the solution can potentially enter the scout phase.
Step 2: Employed Bee Phase: Each employed bee
visits a food source, evaluates its quality, and shares this
information.
● Select a random variable to change
Let the variable be
● Greedy Selection: Here we compare the variables, value of objective functions ‘f’ and fitness values ‘fit’
of the new solution with the old solution based on the greedy selection and we get:
The trail vector will change from 0 to 1, as our solution could not generate new solution.
● Similarly we can generate new solutions for second and third solutions.
Continuing with the same process for second and third solutions we have:
Step 3: Onlooker Bee Phase: Onlookers select food sources based
on the information from employed bees and further explore them.
● An onlooker bee chooses a food source depending on the probability values calculated using the fitness
values provided by employed bees.
The probabaility values can be calculated using: