Zebra Optimization Algorithm
Zebra Optimization Algorithm (ZOA)
- Year introduced
- 2022
- Original authors
- Eva Trojovska; Mohammad Dehghani; Pavel Trojovsky
- Source of inspiration
- Zebras
- Search space
- Continuous
- Optimization types
- Hyperparameter Optimization
- Applied research in the repository
- 0
Overview
It imitates the grazing and anti-predator defence behaviour of zebras. In the grazing phase each individual moves towards the "pioneer zebra" (the best), and in the defence phase it chooses between escaping a lion with a zigzag motion or a group attack on a smaller predator.
Source of inspiration and mechanism

Zebras graze in herds led by an individual that knows the pastures, flee from lions with zigzag movements, and gather to face smaller predators such as hyenas and wild dogs.
Initialization
Random.
Update mechanism
Two phases with greedy acceptance.
Exploration
A group attack towards a random zebra.
Exploitation
Grazing towards the pioneer and escaping with small steps.
Mathematical description
Grazing: x + r(PZ − I·x), where PZ is the pioneer zebra. Defence: with probability 0.5 escaping the lion, x + R(2r − 1)(1 − t/T)x with R = 0.01, otherwise a group attack, x + r(AZ − I·x), towards a random zebra AZ. Greedy acceptance.
Grazing
x_{i,j}^{new,P1} = x_{i,j} + r\,(PZ_j - I\cdot x_{i,j})I random from {1,2}.
Defence
x_{i,j}^{new,P2} = \begin{cases}x_{i,j} + R(2r-1)\left(1-\frac{t}{T}\right)x_{i,j} & P_s \le 0.5\\ x_{i,j} + r\,(AZ_j - I\cdot x_{i,j}) & \text{otherwise}\end{cases}R = 0.01.
Computational complexity: O(T\cdot N\cdot (D + C_f))
Pseudocode
Initialize
for t = 1..T:
PZ = best
for each zebra: foraging toward PZ; accept if better
for each zebra: if Ps <= 0.5: escape lion; else: offensive toward random zebra; accept if better
return PZPython implementation
There is currently no tested python implementation of this algorithm in the lab. We did not include untested code so that it is not used as a reference implementation.
Coefficients
| Parameter | Symbol | Typical value | Range | Description |
|---|---|---|---|---|
| R | R | 0.01 |
Advantages
Almost no tuning parameters.
Limitations
A possible bias towards the origin in the escape phase (a term proportional to x).
Use in artificial intelligence
Domains documented in the card: Machine learning, hyperparameter tuning
Continuous and engineering optimization.
Hybridization potential
These are partnerships suggested theoretically in the card; any resulting design is presented as a "proposed hybrid method" until its results are compared with the literature.
Applied research from the repository
An aspect that did not appear in the current search results within the repository. This does not mean there is no published research outside it.
Original reference
Eva Trojovska; Mohammad Dehghani; Pavel Trojovsky (2022). Zebra Optimization Algorithm: A New Bio-Inspired Optimization Algorithm for Solving Optimization Algorithm. IEEE Access, Institute of Electrical and Electronics Engineers (IEEE).
Verified DOI: 10.1109/ACCESS.2022.3172789
The bibliographic data match the Crossref record (checked 2026-11-20). There is no tested Python code for this algorithm in this version.
Additional original reference: Zebra Optimization Algorithm: A New Bio-Inspired Optimization Algorithm for Solving Optimization Algorithm
