Introduction

Background and problem context

Combined Heat and Power (CHP) systems, also known as cogeneration systems, represent a highly efficient and sustainable energy solution applicable across diverse sectors. By producing electrical and thermal energy, CHP systems significantly enhance overall energy utilization and offer substantial environmental advantages. In the context of the global shift toward cleaner and more efficient energy technologies, CHP systems play a pivotal role in reducing greenhouse gas emissions, enhancing energy reliability, and delivering long-term economic benefits. Depending on the technology and its specific application, CHP systems can achieve efficiency levels ranging from 60% to over 80%.

CHP units are consistent with a wide diversity of fuel sources, involving natural gas, biogas, coal, oil, and renewable energy sources such as biomass and solar thermal energy. Unlike conventional power plants that lose a large part of input energy as heat during electricity generation, CHP systems recover and employ this thermal energy to meet heating demands, thereby pushing total system efficiency to nearly 90% 1,2. Moreover, CHP systems have the prospect to decrease total fuel costs by 10–40% and lower pollutant emissions by 13–18% 3. To completely harness the advantages of CHP systems, it is crucial to address the Combined Heat and Power Economic Dispatch (CHPED) issue, which involves determining the optimum cost-effective schedule for both power and heat generation under various operational constraints 4.

Research gap and motivation

Traditional optimization approaches for solving CHPED include the normal boundary intersection method 5, branch and bound 6, lagrangian approach 7,8, sequential quadratic programming 9, and benders method 10,11. However, these methods often depend heavily on initial conditions, require numerous iterations, and may not consistently converge to the global optimum. Additionally, they can be mathematically complex and computationally intensive.

As a result, heuristic and metaheuristic algorithms have emerged as powerful alternatives for solving CHPED problems. A comprehensive survey of heuristic methods for CHPED is presented in 12. Genetic Algorithm (GA)-based approaches have been widely applied to minimize total generation costs while taking into consideration valve-point-loading effects (VPLEs) and transmission power losses (PLs) 13. Enhanced GA variants featuring improved crossover and mutation strategies 14, as well as the Non-dominated Sorting Genetic Algorithm II (NSGA-II) 15, have demonstrated effectiveness in handling mixed-variable scheduling tasks and integrating energy storage systems. Particle Swarm Optimizer (PSO) has been extensively employed for CHPED 16, with modifications such as time-varying acceleration coefficients to improve convergence behavior and prevent premature stagnation. VPLEs are often modeled using sinusoidal components added to the cost function. To address uncertainties in demand and renewable energy availability, PSO has been integrated with Monte Carlo simulations 17. Additionally, PSO has been utilized to assess dispatch strategies for reducing fuel consumption in coal-fired CHP plants 18.

Hybrid algorithms have been proposed to solve the CHPED problem. A hybrid PSO–NSGA-II approach simultaneously optimized both cost and emissions while incorporating transmission PLs 19. However, many of these methods have been validated only on small-scale systems (e.g., those comprising 5 to 7 units), limiting their generalizability. The Manta Ray Foraging Optimization (MRFO) has also been implemented to address generation scheduling in systems integrating wind power and VPLEs, achieving cost reductions of up to 8% across both small-scale (5-unit) and large-scale (96-unit) configurations under varying load conditions 20. The Cuckoo Search Optimizer (CSO) has emerged as a viable approach for addressing the CHPED issue 20,21,22,23. Its primary objective is to reduce overall fuel costs while meeting electricity and heat demands, considering constraints such as VPLEs and transmission PLs. In 21, CSO was tested on systems of various sizes, including small (5-unit), medium (24-unit), and large (48-unit) configurations. The 5-unit system was evaluated under three distinct heat and power demand scenarios. Similarly, the study in 22 demonstrated CSO’s effectiveness across six different test networks with 4, 5, 7, 11, 24, and 48 units. The methodology proposed in 23 was applied to five case studies, three involving quadratic cost functions without PLs, and two with non-convex cost functions. Several other metaheuristic approaches have also been employed to solve the CHPED problem, including the grey wolf optimizer (GWO) 24, heap-based optimization 2, group search optimization 25, gravitational search algorithm 26, marine predators algorithm 27, kho-kho optimization 28, a hybrid of weighted vertices-based approach and PSO 29. A mixed integer model was proposed to solve the CHPED for 4 units, 5-units, 24-unit, 48-unit, and 96 unit systems 30. An improved version of artificial rabbits optimization based on fitness distance balance was presented for solving the CHPED of 4-unit, 5-unit, 7-unit, 24-unit, 48-unit, 96-unit, and 192-unit systems 31. The artificial hummingbird algorithm based integrates a linear controlling strategy was developed to solve CHPED for different systems 32. An improved version of AVOA based orthogonal oppositional methodology was proposed to solve the CHPED for 48-unit system33. A hybrid optimizer based on Harris hawk’s optimizer (HHO), and imperialist competitive algorithm (ICA) was employed to solve the CHPED of 48-unit, 84-unit, and 96-unit systems 34.

It is worth mentioning here that metaheuristic optimization algorithms can solve several optimization problems where in a hybrid particle swarm optimizer was presented for optimal coordination of overcurrent relay 35 and it can be also applied for optimal placement of electric vehicle stations in distbution grids 36. A hybrid simulated annealing (SA) with particle swarm optimization (PSO) was utilized to control variable frequency drives37. Artificial intelligence (AI) was proposed for improving the accuracy of objective and physical pressure ratings 38. A fast sparse Bayesian learning algorithm was developed for superresolution and the coherent processing of multi-band radar data 38. In 39, a deep genetic algorithm was suggested for optimizing the channel for signal integrity. In 40, a Bayesian posterior loss function technique and a heuristic frequentist approach technique was proposed for to enhance the human decision making.

DBO a robust optimization algorithm that has been applied to solve different optimization problems 41. However, several modified versions of DBO were proposed to overcome the stagnation of the traditional DBO to local optima, premature convergence and its low performance where in 42, a modified DBO was presented based on Mean Differential Variation and Latin hypercube sampling. A multi-strategy was integrated to DBO based on Levy distribution, two separate cross operators, and Beta distribution to solve path planning problem 43. A t-distribution variation approach was applied to enhance the searching ability of the DBO to solve different optimization problems 44. Three improvement strategies were integrated to DBO to improve its performance including T-distribution mutation, differential evolutionary variation, cooperative search mechanism and cubic chaotic mapping 45. The fractional order calculus methodology was applied with DBO to boost its searching performance in image segmentation 46. At the end of this context, the performance of the DBO should be improved for solving large scale problems. Thus, in this paper, three improvement strategies were integrated into DBO to solve the CHPED problem including the fitness distance balance (FDB), Chaotic mutation (CM), and adaptive local search approach (ALSA).

The key contributions

From the previous review, the main associated gap of the applied methods for solving the CHPED is that some papers solved CHPED without considering VPLEs while some papers solved the CHPED with considering PLs only, and some papers solved the CHPED with considering the POZs only. The aim of the papers is to fill the research gap by solving the CHPED of small, medium and large-scale systems considering VPLEs, PLs, and POZs. In addition to that, a modified optimizer is presented to overcome the shortage of traditional DBO via integration of three improvements including ALSA, CM and FDB. Therefore, the contributions to this study can be depicted as follows:

  • New Modified Dung Beetle Optimizer (MDBO) is proposed to solve the CHPED based on boosting the exploitation and exploration of the conventional DBO using three strategies including ALSA, CM and FDB.

  • MDBO performance has been rigorously assessed using standard benchmark test and CEC-2019 suites to verify its efficiency and robust performance.

  • Solving the CHPED problem, considering PLs, VPLE, and POZs for 4 different test systems and the results obtained were compared with other optimization algorithms including SCSA, AVOA, SCA, HHO, GWO, LCA, ZOA, and WOA.

This article is structured as follows: Section "Problem Formulation" outlines the features of CHP units and formulates the economic dispatch problem using DBO and MDBO, considering VPLEs, PLs, and POZs. Section "Methodology" describes the test systems used for validation, followed by optimization outcomes presented in Section "Numerical Results". A comprehensive evaluation of the suggested approach is provided in Section "Conclusions", and the conclusions are summarized in Sect. 6.

Problem formulation

The objective of the CHPED problem is to achieve the lowest possible overall operational cost by optimally coordinating three categories of generation units: those producing only electricity, those generating solely heat, and CHP units. To evaluate different solutions, a fitness function is constructed, taking into account the amount of heat and power generated by each unit. The aggregate operational cost is then determined by summing the individual expenses associated with each type of generation unit, as outlined below:

$$Cost_{CHP} = \mathop \sum \limits_{i = 1}^{{N_{p} }} Cost\user2{ }_{i}^{P} \left( {P_{i}^{p} } \right) + \mathop \sum \limits_{j = 1}^{{N_{u} }} Cost\user2{ }_{j}^{H} \left( {H_{j}^{u} } \right) + \mathop \sum \limits_{k = 1}^{{N_{f} }} Cost\user2{ }_{k}^{CHP} \left( {P_{k}^{f} ,H_{k}^{f} } \right)$$
(1)

where, \({N}_{p}\) refers to the units dedicated solely to electricity generation, \({N}_{u}\) signifies those units that produce only heat, and \({N}_{f}\) indicates the CHP units. The cost terms \({\text{cost }}_{i}^{P}\), \({\text{cost }}_{j}^{H}\), and \({\text{cost }}_{k}^{CHP}\) represent the cost of generation cost of \({i}^{th}\) power-only units, the \({j}^{th}\) heat-only unit, and the \({k}^{th}\) CHP unit. The cost functions for these units are expressed as follows:

$${Cost }_{i}^{P}\left({P}_{i}^{p}\right)={A}_{i}{\left({P}_{i}^{p}\right)}^{2}+{B}_{i}{P}_{i}^{p}+{Q}_{i}+\left|{T}_{i}\text{sin}\left({G}_{i}\left({P}_{i}^{p,Min}-{P}_{i}^{p}\right)\right)\right|$$
(2)
$${Cost }_{j}^{H}\left({H}_{j}^{u}\right)={A}_{j}{\left({H}_{j}^{u}\right)}^{2}+{B}_{j}{H}_{j}^{u}+{Q}_{j}$$
(3)
$${Cost }_{k}^{CHP}\left({P}_{k}^{f},{H}_{k}^{f}\right)={A}_{k}{\left({P}_{k}^{f}\right)}^{2}+{B}_{k}{P}_{k}^{f}+{Q}_{k}+{T}_{k}{\left({H}_{k}^{f}\right)}^{2}+{G}_{k}{H}_{k}^{f}+{V}_{k}{P}_{k}^{f}{H}_{k}^{f}$$
(4)
  • For power-only units, cost was modeled using coefficients \({A}_{i}, {B}_{i}\), \({Q}_{i}, {T}_{i},\) and \({G}_{i}\), representing the cost parameters for \({i}^{th}\) electricity production units.

  • For heat-only units, cost was modeled using coefficients \({A}_{j}, {B}_{j}\), and \({Q}_{j}\), which account for the heat generation expenses.

  • For CHP units, cost was represented using coefficients \({A}_{k}, {B}_{k}{, Q}_{k}, {T}_{k}, {G}_{k}\), and \({V}_{k}\)​, which captures the combined cost of electricity and heat production for the \({k}^{th}\) units 47.

Constraints in the CHPED problem

The CHPED problem formulation includes both equality and inequality constraints to ensure energy balance and adherence to operational limits:

Equality constraints

The equality constraints include the power balanced with and without power losses asdescribed in Eqs. (5) and (6), as well as the heat balanced of hsystem as decribed in (7). In addation to that the equality constraints include the capacities of only-power units, heat-only units and the CHP units as depicted in (8), (9), and (10), respectivly. Furthermore, the prohibted zones of the generation units are described in (11).

$$\mathop \sum \limits_{i = 1}^{{N_{p} }} P_{i}^{p} + \mathop \sum \limits_{k = 1}^{{N_{f} }} P_{k}^{f} - P_{{\text{demand }}} = 0$$
(5)
$$\mathop \sum \limits_{i = 1}^{{N_{p} }} P_{i}^{p} + \mathop \sum \limits_{k = 1}^{{N_{f} }} P_{k}^{N} - P_{{\text{demand }}} - P_{{\text{losses }}} = 0$$
(6)

where; Plosses is power losses, while Pdemand is the power demand.

$$\mathop \sum \limits_{k = 1}^{{N_{f} }} H_{k}^{f} + \mathop \sum \limits_{j = 1}^{{N_{u} }} H_{j}^{u} - H_{{\text{demand }}} = 0$$
(7)
$$P_{power\_only} = \mathop \sum \limits_{i = 1}^{{N_{p} }} \left[ {Max\left( {P_{i}^{p} - P_{i}^{pMax} ,0} \right) + Max\left( {P_{i}^{pMin} - P_{i}^{p} ,0} \right)} \right]$$
(8)
$$P_{heat\_only} = \mathop \sum \limits_{j = 1}^{{N_{u} }} \left[ {Max\left( {H_{j}^{u} - H_{j}^{u, Max } ,0} \right) + Max\left( {H_{j}^{u,Min} - H_{j}^{u} ,0} \right)} \right]$$
(9)
$$P_{CHP} = \mathop \sum \limits_{k - 1}^{{N_{f} }} \left[ {\begin{array}{*{20}c} {Max\left( {P_{k}^{f} - P_{k}^{f,Max} \left( {H_{k}^{f} } \right),0} \right) + Max\left( {P_{k}^{f,Min} \left( {H_{k}^{f} } \right) - P_{k}^{f} ,0} \right) + } \\ {Max\left( {H_{k}^{f} - H_{k}^{f,Max} \left( {P_{k}^{f} } \right),0} \right) + Max\left( {H_{k}^{fMin} \left( {P_{k}^{f} } \right) - H_{k}^{f} ,0} \right)} \\ \end{array} } \right]$$
(10)
$$P_{{POz_{s} }} = \mathop \sum \limits_{i = 1}^{{N_{p} }} \left[ {\xi_{i} \mathop \sum \limits_{V = 1}^{{Z_{i} }} Min\left( {Max\left( {P_{i}^{p} - P_{i,V}^{L} ,0} \right),Max\left( {P_{i,V}^{U} - P_{i}^{p} ,\;0} \right)} \right)} \right]$$
(11)

The inequality constraints

Each power-only unit must operate within its designated generation limits. These constraints ensure that the power output from the \({i}^{th}\) unit stays within the allowable lower and upper bounds.

$$P_{{i{\text{,Min}}}}^{{power\_only_{ } }} \le P_{i}^{power\_only} \le P_{i,Max}^{{power\_only_{ } }} i = 1, \ldots ,N_{p}$$
(12)

The heat output from each heat-only unit is restricted by its minimum and maximum generation capabilities.

$$\left({H}_{j}^{f}\right)\le {H}_{j}^{f}\le \left({H}_{j}^{f}\right)j, {\forall }_{j}$$
(13)

where \({H}_{j}^{{f}_{Max}}\) and \({H}_{j}^{{f}_{Min}}\) represent the upper and lower restrictions of heat output from the \({j}^{th}\) unit, correspondingly.

The CHP units concurrently generate both heat and power, are also subject to operational limits.

$${H}_{j}^{{f}_{Min}}\left({P}_{j}^{f}\right)\le {H}_{j}^{f}\le {H}_{j}^{{f}_{Max}}\left({P}_{j}^{f}\right)j=1,\dots ,{N}_{f}$$
(14)
$${H}_{k}^{{u}_{Min}}\le {H}_{k}^{u}\le {H}_{k}^{{u}_{Max}}k=1,\dots ,{N}_{u}$$
(15)

The electrical power generation from the \({k}^{th}\) CHP unit must lie within the bounds \({P}_{j}^{{f}_{\text{Max }}}\) and \({P}_{j}^{{f}_{\text{Min }}}{H}_{k}^{f}\), which denote the lower and upper bounds of the power output capacity for the respective unit, respectively. Likewise, the heat output from the same CHP unit must fall within the limits \({H}_{j}^{{f}_{Min}} {P}_{k}^{f}\) \({H}_{j}^{{f}_{Max}} {P}_{k}^{c}\), which denote the minimum and maximum allowable heat generation from the \({k}^{th}\) CHP unit, respectively.Also, Certain regions within the power generation range are deemed infeasible due to operational constraints or safety considerations; these segments are referred to as POZs. The feasible power output range for the \({i}^{th}\) power-only unit is characterized in accordance with Eq. (16). Here, \({P}_{i}^{n,L}\) and \({P}_{i}^{n,U}\) represent the lower and upper limits of the \({n}^{th}\) POZ for the \({i}^{th}\) power-only unit, respectively, while \({Z}_{i}\) denotes the total count of such POZs associated with the unit.

$$\left\{\begin{array}{c}{P}_{i}^{\text{ Min }}\le {P}_{i}^{power\_only}\le {P}_{i}^{Max}\\ {P}_{i}^{n,l}\le {P}_{i}^{powe{r}_{only}}\le {P}_{i}^{n,U}, {\forall }_{n} \in \left[\text{1,2},\dots ,{Z}_{i}\right]\\ {P}_{i}^{{Z}_{1},U}\le {P}_{i}^{p}\le {P}_{i}^{p,Max}\end{array}\right.$$
(16)

Methodology

Dung beetle optimization (DBO)

The Dung Beetle Optimization (DBO) algorithm is a biologically inspired based metaheuristic that simulates the unique behaviors of the dung beetles. It incorporates four key activities: Rolling, Spawning, Foraging, and Stealing, which collectively guide the population of virtual dung beetles searching for optimal solutions.

Rollerball Dung Beetle (rolling)

Dung beetles roll dung balls in straight paths while navigating using sunlight. This behavior is modeled in DBO for updating the beetle’s position using Eq. (22) 41:

$$\begin{array}{c}{x}_{i}(tt+1)={x}_{i}(tt)+\alpha \cdot k\cdot {x}_{i}(tt-1)+b\cdot \Delta x\\ \Delta x=\left|{x}_{i}(tt)-{X}^{w}\right|\end{array}$$
(17)

where: \({x}_{i}(tt)\) is the position of the ith beetle at time \((tt)\). \(\alpha\) determines if the beetle deviates from its original path (random directional factor, randomly set to 1 or -1). \(k\) is a deflection coefficient (between 0 and 0.2). \(b\) is a constant in the range [0, 1]. \(\Delta x\) simulates the beetle’s displacement toward the light source. If the beetle encounters an obstacle, it simulates directional change via a dancing behavior, modifying its position based on Eq. (23).

$${x}_{i}(tt+1)={x}_{i}(tt)+\text{tan}(\theta )\left|{x}_{i}(tt)-{x}_{i}(tt-1)\right|$$
(18)

The angle θ [0, π] determines direction adjustment, with no update occurring when θ = 0, π ∕ 2, and π.

Spawning behavior

Dung beetles choose safe zones for laying eggs. DBO models this through adaptive boundaries for local exploration:

$$L{b}^{*}=max\left({X}^{*}\times (1-R),Lb\right)$$
(19)
$$U{b}^{*}=min\left({X}^{*}\times (1+R),Ub\right)$$
(20)
$$R=1-\frac{t}{{T}_{max}}$$
(21)

where, \(L{b}^{*}\) and \(U{b}^{*}\) is the lower and upper constraints of the spawning region, \(Lb\) and \(Ub\) is the Original lower and upper constraints, \({X}^{*}\) is the current best solution, \(R\) is the decay factor over iterations, while \({T}_{max}\) is the maximum number of iterations.

The position update in spawning is defined by Eq. (22), using random values \(b1\) and \(b2\).

$$Xi(tt + 1) ={X}^{*} + b1 \times (Xi(tt) - L{b}^{*}) + b2 \times (Xi(tt) - U{b}^{*})$$
(22)

Foraging

Foraging simulates a global search for optimal solutions, influenced by the best global position, modeled as:

$$L{b}^{b}=max\left({X}^{b}\times (1-R),Lb\right)$$
(23)
$$U{b}^{b}=min\left({X}^{b}\times (1+R),Ub\right)$$
(24)

where \({X}^{b}\) is the best global position. The position update for foraging by:

$${x}_{i}\left(tt+1\right)=Xi(tt)+{c}_{1}\times \left(x\left(tt\right)-L{b}^{b}\right)+{c}_{2}\times ({x}_{i}\left(tt\right)-U{b}^{b})$$
(25)

where, \({c}_{1}\) is the normally distributed random number, and \({c}_{2}\) : random vector within [0, 1].

Stealing behavior

Some beetles exhibit kleptoparasitic behavior by stealing dung balls from others. This behavior is analogous to the exploitation process in optimization, where certain individuals mimic others to enhance convergence toward promising regions in the search space. In the algorithm, this behavior is modeled using the global best location \({X}^{b}\). The location update for a stealing beetle is given by:

$${x}_{i}\left(tt+1\right)={X}^{b}+S\times g\times \left(|{x}_{i}\left(tt\right)-{X}^{*}|\right)+(|{X}_{i}\left(tt\right)-{X}^{b}|)$$
(26)

where \(S\) is a constant (0.5), \(g\) is a random variable and \({X}^{*}\) is the best position globally.

Modified Dung Beetle optimizer (MDBO) algorithm

To enhance the standard DBO’s performance, the proposed MDBO incorporates the following three key improvements:

Fitness distance balance (FDB)

FDB is designed to improve global exploration 48,49,50,51,52,53,54,55,56. In this approach, the populations positions are updated based on a score vector derived from their objective function and the distance between each population and the best solution. The score vector can be determined based on the normalized distance \(\text{norm}\left({DS}_{i}\right)\) and fitness values \(\text{norm}\left({F}_{i}\right)\) as follows:

$${D}_{i}=\sqrt{{\left({X}_{i}^{1}-{X}_{1}^{b}\right)}^{2}+{\left({X}_{i}^{2}-{X}_{2}^{b}\right)}^{2}+\cdots +{\left({X}_{i}^{d}-{X}_{3}^{b}\right)}^{2}}$$
(27)
$$F=\left[{F}_{1},{F}_{2},\cdots ,{F}_{n}\right]$$
(28)
$$D=\left[{D}_{1},{D}_{2},\cdots ,{D}_{n}\right]$$
(29)

where \(\text{D}\) and \(\text{F}\) represent the distance and the fitness vectors.

$$norm\left({DS}_{i}\right)=\frac{{D}_{i}-{D}_{min}}{{DS}_{max}-{DS}_{min}}$$
(30)
$$\begin{array}{c}\\ norm\left({F}_{i}\right)=\frac{{F}_{i}-{F}_{min}}{{F}_{max}-{F}_{min}}\end{array}$$
(31)

\(min\) and \(max\) are subscript denote the lower and maximum values, respectively. The score of each population (\({Sr}_{i})\) can be obtained as follows:

$${Sr}_{i}=\varepsilon \times \left(1-norm\left({F}_{i}\right)\right)+(1-\varepsilon )\times norm\left({D}_{i}\right)$$
(32)
$$\varepsilon =0.5\times \left(1+\frac{t}{{t}_{max}}\right)$$
(33)

where, \({t}_{max}\) represents the maximum number of iterations permitted, while t denotes the iteration count currently being executed.

Chaotic mutation (CM)

Introduces chaos-based variation to prevent premature convergence and helps escape local optima, specifically in later phases of the search. The chaotic mutation (CM) mechanism enhances the exploration capability of the proposed optimizer by assigning new solution positions based on principles from chaos theory 57. Specifically, the logistic chaotic map is employed for this mutation process, as defined in 58,59:

$${\tau }{\prime}=\mu \tau (1-\tau )$$
(34)
$${X}_{i}(t+1)={X}_{i}(tt)+{\tau }{\prime}\times \, \left({U}_{b}-{L}_{b}\right)$$
(35)

where \(\tau^{\prime }\) refers to the logistic chaotic paramter in which \(\tau^{\prime } \ne \left\{ {0.0, 0.25, 0.75, 0.5, 1.0} \right\}\). \(\tau\) represents random paramter between 0 and 1. \(\mu\) equals to 4.

Adaptive local search approach (ALSA)

The Adaptive Local Search Algorithm (ALSA) is designed to improve the local exploitation capability by updating each agent’s position relative to the current best solution. During the iteration process, the population members are adjusted according to:

$${X}_{i}\left(tt+1\right)={X}^{b}\left(1-\frac{t}{{t}_{max}}\right)+\left(mean(X\left(tt\right))- {X}^{b}\right)\times rand$$
(36)

where \(rand\) is a random value in the range of [0,1].

This adaptive mechanism ensures that agents remain locally focused on the best-known position while retaining randomness for exploration. Figure 1 illustrates the population update mechanism based on ALSA. A pseudo code the proposed MDBO is depicted in algorithm 1.

Fig. 1
figure 1

The updated populations based on (ALSA).

The pseudo code of the proposed MDO is presented in Algorithm1.

Algorithm 1
figure a

Pseudo code the proposed MDBO.

Numerical results

Validation and analysis of simulation

This section presents and evaluates the performance of the proposed MDBO in solving the CHPED problem for different test systems, including four, seven, twenty-four-unit, and forty-eight configurations. Initially, the MDBO is benchmarked against 23 standard test functions and the CEC-2019 test suite. The description of standard functions is given in 60,61 while the description of CEC-2019 functions is provided in 62,63. Its performance is compared with nine state-of-the-art optimization algorithms, namely: Whale Optimization Algorithm (WOA) 64, Sand Cat Swarm Optimization (SCSO) 65, Zebra Optimization Algorithm (ZOA)66, African Vultures Optimization Algorithm (AVOA) 67, Grey Wolf Optimizer (GWO) 68, Harris Hawks Optimization (HHO)69, Liver Cancer Algorithm (LCA) 70, and Dung Beetle Optimizer (DBO) 41. All simulations were executed using MATLAB 2021b on a Core i7 processor (2.5 GHz, 8 GB RAM). Table 1 summarizes the parameter settings of the comparative optimization algorithms.

Table 1 The selected parameters of the optimization methods.

Benchmark validation

To validate the effectiveness of MDBO compared to the statistical outcomes of other methods (provided in Table 1), extensive experiments were conducted using two widely accepted benchmark suites. The statistical evaluation includes convergence curves, box plots, and non-parametric significance tests, such as the Wilcoxon rank-sum test and Friedman’s mean rank test.

Statistical analysis

The statistical performance of MDBO and the comparative algorithms is presented in Table 2 for the 23 standard benchmark functions and Table 3 for the CEC-2019 suite. The metrics considered include average, best, and worst, standard deviation and simulation time of the obtained results. Across most test functions, MDBO demonstrated superior performance in terms of average and best values, indicating its effectiveness and robustness. However, the computational time of the proposed MDBO is the highest compared to the original DBO and the other optimization algorithms due to the three integrated modifications.

Table 2 Statistical performance on 23 standard benchmark functions.
Table 3 Statistical performance on CEC-2019 benchmark suite.

Convergence analysis

The convergence carve of the comparative optimizers for the standard benchmark functions and CEC-2019 are displayed in Figs. 2 and 3, respectively. According to Fig. 2, the proposed MDBO has stable and fast convergence characteristics compared to the other optimization algorithms for most benchmark functions where there is notable difference especially for F1 to F6, F14, F15, F21, F22, and F23 while the convergence of F5, F6, and F12 the AVOA is the best and for F9, the WOA is the best. Likewise, the convergence of the MDBO is the best compared to other optimization techniques for CEC-2019 functions as depicted in Fig. 3, except the AVOA is the best for CEC06 and ZOA is the best for CEC08, and CEC09 while the GWO is the best for CEC10.

Fig. 2
figure 2figure 2figure 2figure 2

Convergence response of the proposed and other state-of-the-art techniques using standard 54 benchmark functions.

Fig. 3
figure 3figure 3

Convergence response of the proposed and other state-of-the-art techniques using CEC-2019 test-suit.

Boxplot analysis

Boxplot is a visual representation of obtained results by the comparative optimizers to test the performance and verify the effectiveness of the proposed optimizer. It is worth mentioning here that the narrowest boxplot means that there is no massive difference between the results obtained. Figure 4 and Fig. 5 shows the boxplot of the comparative optimizers for the classic and CEC-2019 functions, respectively. As depicted in Figs. 4 and 5, the MDBO has the narrowest boxplot for most functions.

Fig. 4
figure 4figure 4figure 4figure 4

Boxplot response of the proposed and other state-of-the-art techniques using standard benchmark functions.

Fig. 5
figure 5figure 5

Boxplot response of the proposed and other state-of-the-art techniques using CEC-2019 test-suit.

Wilcoxon rank-sum test

The Wilcoxon rank-sum test, also known as the Mann–Whitney U test, is applied to statistically verify significant differences in performance. This non-parametric test is suitable for small or non-normally distributed datasets, comparing medians instead of means. The p-values of Wilcoxon test results which obtained from testing both benchmark suites are summarized in Table 4 for standard benchmarks and Table 5 for CEC-2019 suite. Most comparisons show statistically significant improvements by MDBO, supporting its efficacy over existing methods.

Table 4 Wilcoxon Rank Sum Test Results for Standard Benchmark Functions.
Table 5 Wilcoxon Rank Sum Test Results for CEC-2019 Benchmark Suite.

Friedman mean rank test

The Friedman mean rank test serves as a non-parametric statistical tool designed to assess the significance of differences among several optimization algorithms by evaluating their average rankings across a set of benchmark functions. Figures 6 and 7 illustrate the Friedman mean rank values obtained from two distinct benchmark suites. The results demonstrate that the proposed MDBO consistently secures the lowest mean rank, reflecting its superior performance relative to contemporary optimization methods. In contrast, the Sine Cosine Algorithm (SCA) exhibits the highest mean rank, indicating the least favorable performance within this comparative framework.

Fig. 6
figure 6

Friedman mean rank test results for 23 standard benchmark functions.

Fig. 7
figure 7

Friedman mean rank test results for CEC-2019 benchmark suite.

Application of MDBO for different CHPED test systems

This section focuses on applying the proposed MDBO to solve four CHPED test systems: 4-unit, 7-unit, 24-unit, and 48-unit configurations. Table A.1 in Appendix A presents the specifications of the studied systems. The simulation setup (including the number of agents, iterations, and runs) remains consistent across all test systems for a fair comparison, following the parameters listed in Table 1.

Test system-1 (4-unit system)

The first test system consists of four generating units, including a single power-only unit, two CHP units, and one heat-only unit. This configuration is required to satisfy an electrical demand of 200 MW and a thermal demand of 115 MWth. The parameters defining the cost functions are details are taken from 71, while the permissible operating regions for the CHP units are depicted in Figs. 8 and 9.

Fig. 8
figure 8

Feasible region for CHP Unit 2 in Test System-1.

Fig. 9
figure 9

Feasible region for CHP Unit 3 in Test System-1.

In this configuration, power losses (Ploss), VPLE, and POZs are not considered. The aim is to minimize the whole operational cost without losses. Simulations were conducted using MDBO and other optimization methods. Table 6 presents the statistical outcomes (best, average, worst) for the 4-unit system, where the best average and optimal response are attained by the MDBO to decrease the entire cost of the system. Indeed, Table 7 provides comparative performance results. Figures 10 and 11 show the convergence trends and boxplot comparisons, where the efficient and stable response was observed by the proposed MDBO.

Table 6 Statistical performance results for 4-unit system (without considering power losses).
Table 7 Comparative analysis of the optimizers for 4-unit systems studied (without considering power losses).
Fig. 10
figure 10

Convergence behavior of various optimizers for the 4-unit system.

Fig. 11
figure 11

Boxplot analysis of optimization results for the 4-unit system.

According to Tables 6 and 7, the lowest operational cost achieved by the MDBO was $9,257.1, outperforming (lower than) other algorithms by varying ratios: SCSO (0.0011%), SCA (0.0248%), HHO (0.0992%), GWO (0.0054%), LCA (0.504%), ZOA (0.0151%), WOA (0.1919%), RGA (0.0667%), ARO (0.00106%), GA2 (2.064%), GA1 (0.1089%), ACSA (2.0641%). It is noted here that some results for this case, the values observed were identical because of the low population size and iteration, but overall, the response of the proposed optimizer is observed to be better than the other state-of-the-art techniques.

Table B.1 in Appendix B shows the optimal scheduling outcomes for this test case. The solutions obtained by MDBO adhered to all operational constraints, with no violations observed.

Test system-2 (7-unit system)

This system is composed of a total of seven generating units, comprising four power-only units, two CHP units, and one heat-only unit. It is tasked with fulfilling a power demand of 600 MW alongside a thermal demand of 150 MWth. This system is analyzed under three distinct operational scenarios:

  • Case 1: CHPED with VPLE,

  • Case 2: CHPED with VPLE and PLs,

  • Case 3: CHPED with VPLE, PLs, and POZs.

The cost function parameters are taken from reference 71, and a comprehensive discussion of the findings from these three cases is provided in the upcoming subsections.

CASE-1: CHPED with VPLE

In this case, only the VPLE was incorporated into the CHPED formulation. Simulations were performed using the MDBO and several comparative optimization algorithms under the same parameter settings. The statistical performance results are reported in Table 8. MDBO achieves the most cost-effective and consistent outcomes.

Table 8 Statistical results for the 7-unit system considering VPLE.

Figures 12 and 13 illustrate the convergence curves and boxplot responses obtained by various optimizers for minimizing the cost function. These figures demonstrate that the MDBO exhibits faster convergence and lower variability, indicating a more reliable and stable solution trajectory compared to the competing methods.

Fig. 12
figure 12

Convergence behavior of different optimizers for 7-unit system with VPLE.

Fig. 13
figure 13

Boxplot analysis for cost values of different optimizers for 7-unit system with VPLE.

According to Tables 8 and 9, the MDBO achieved the lowest total generation cost of $10,091.92, outperforming several state-of-the-art optimizers. Specifically, the cost obtained by MDBO was lower than those of DBO by 0.502%, SCSO by 0.247%, AVOA by 0.249%, SCA by 1.204%, HHO by 0.890%, GWO by 0.127%, LLCA and LCA by 0.199%, ZOA by 0.516%, WOA by 0.625%, MRFO by 0.0041%, and ARO by 0.3051%. These results clearly demonstrate MDBO’s superior performance in minimizing total generation cost under the system conditions considered.

Table 9 Comparative cost performance across various algorithms for the 7-units system considering VPLE.

Table C.1 in Appendix C presents the optimal CHPED scheduling for the studied 7-unit system, considering the VPLE. The optimal schedule further validates MDBO’s robustness in addressing the nonlinearities and constraints introduced by VPLE, highlighting its potential for practical deployment in complex CHPED problems.

CASE-2: CHPED with VPLE and PL

In the second case of Test System-2, the VPLE and transmission PLs were both considered. This scenario adds complexity by considering real power losses, making it more representative of practical CHPED applications. To ensure a consistent comparison, the same simulation parameters were applied across all algorithms. The statistical results of various optimization techniques, including the proposed MDBO, are presented in Table 10. Among the examined algorithms, MDBO consistently produced the best cost outcomes with faster convergence and a more reliable distribution of results.

Table 10 Statistical results of the 7-unit system considering VPLE and PLs.

Figures 14 and 15 illustrate the convergence behavior and boxplot distributions of the cost function achieved by various optimization algorithms considering VPLEs and PLs constraints. The proposed MDBO demonstrated both efficient and stable performance, achieving the lowest total system cost. As illustrated in these figures, the MDBO algorithm demonstrated a notably faster convergence rate relative to the other methods while simultaneously preserving a high degree of solution consistency, as evidenced by the diminished variability observed over multiple execution runs.

Fig. 14
figure 14

Convergence behavior of cost by different optimizers for the 7-unit system with VPLE and PLs.

Fig. 15
figure 15

Boxplot comparison for different optimizers for the 7-unit system with VPLE and PLs.

According to Tables 10 and 11, the minimum cost achieved by MDBO was $10,215.61, which was superior to those attained by the other optimizers. The corresponding percentage differences were: DBO (0.504%), SCSO (0.210%), AVOA (0.210%), SCA (1.118%), HHO (0.707%), GWO (0.0805%), LCA (0.167%), ZOA (0.488%), WOA (0.549%), MRFO (0.0037%), ARO (0.2806%).

Table 11 Comparative performance of MDBO and other optimizers for 7-unit system VPLE and PLs.

Table D1 in Appendix D shows the optimal CHPED scheduling for the studied 7-unit system, considering both VPLEs and PLs. The table compares results from various optimization algorithms, highlighting how the proposed MDBO performs in comparison to others. The results under this scenario highlight the robustness and adaptability of MDBO in handling the complex constraints of the CHPED model, effectively addressing both VPLE and PLs simultaneously.

CASE-3: CHPED with VPLE, PLs, and POZs

The third and most complex case incorporates all major nonlinearities, VPLEs, PLs, and POZs, into the CHPED model, resulting in a highly constrained and realistic optimization scenario. The transmission loss coefficients (B-matrix) used are the same as those in Case 2 of Test System 3, as defined in Eq. (21), while the parameters for the POZs are details taken from the reference 71.

The inclusion of POZs introduces non-convex constraints, which can lead traditional optimization algorithms to suffer from premature convergence or entrapment in local optima. This case, therefore, provides a comprehensive benchmark for evaluating the robustness and effectiveness of the MDBO in handling real-world operational complexities. The optimization performance of MDBO was benchmarked against several state-of-the-art algorithms, with statistical comparisons presented in Table 12. MDBO successfully achieved both the lowest average fuel cost and the best optimal solution, demonstrating its superior capability in addressing the challenges posed by this highly constrained CHPED problem.

Table 12 Statistical results for the 7-unit system considering VPLEs, PLs, and POZs.

Figures 16 and 17 illustrate the convergence behavior and boxplot distributions of the cost minimization results obtained by MDBO and other studied benchmark optimizers for the CHPED system incorporating VPLEs, PLs, and POZs. The proposed MDBO demonstrates both efficiency and stability, consistently achieving lower cost values in this highly constrained scenario. As shown in these figures, MDBO exhibits rapid convergence and strong reliability, even in the presence of complex non-linear and non-convex constraints, further validating its robustness and effectiveness in solving real-world CHPED problems.

Fig. 16
figure 16

Convergence trend for the 7-unit system with VPLEs, PLs, and POZs.

Fig. 17
figure 17

Boxplot of results of the 7-unit system with VPLEs, PLs, and POZs.

As shown in Tables 12 and 13, the cost obtained using MDBO was 10,101.28$, outperforming all other techniques with cost differences as follows: DBO (0.445%), SCSO (0.508%), AVOA (0.523%), SCA (1.198%), HHO (0.634%), GWO (0.159%), LCA (1.154%), ZOA (0.581%), WOA (0.784%), HTS (0.0296%), BLPSO (0.00028%), NDE (0.0324%), ARO (0.139%), GSO (0.0007%), and IGA-NCM (0.134%).

Table 13 Comparative performance of MDBO against others studied optimization techniques for the 7-unit system considering VPLEs, PLs, and POZs.

Table E1 in Appendix E presents the optimal CHPED scheduling for the studied 7-unit system, considering VPLEs, PLs, and POZs. The table compares the results obtained using several optimization algorithms, including the proposed MDBO, to clarify the performance differences among these algorithms. It is important to note that, across all three cases of Test System 2 (as detailed in Tables C.1, D.1, and E.1), no constraint violations were observed. All system requirements were fully satisfied, confirming the validity of the solutions obtained. This demonstrates the reliability of MDBO in effectively handling complex, multi-constrained CHPED problems, reinforcing its suitability for real-world applications.

Test system-3 (24-unit system)

The third test system consists of a CHPED system comprising 24 generating units, which include 13 power-only units, 6 CHP units, and 5 heat-only units. The system is required to meet 2,350 MW of electrical power and 1,250 MWth of thermal demand. The cost coefficients and operational limits for this system are details taken from reference 71, while the feasibility boundaries of CHP units are depicted in Figs. 1821. The objective of this test case is to minimize the total operating cost, with cost functions that account for power transmission losses.

Fig. 18
figure 18

Feasibility limits for CHP units 14,16 in Test System-3.

Fig. 19
figure 19

Feasibility limits for CHP units 15,17, in Test System-3.

Fig. 20
figure 20

Feasibility region for CHP unit 18 in Test System-3.

Fig. 21
figure 21

Feasibility region for CHP unit 19, in Test System-3.

The simulations for this large-scale CHPED case were conducted using the input parameters specified in Table 1, applying various optimization algorithms, including the proposed MDBO. This complex test case includes PLs, making it a challenging benchmark for assessing the scalability and robustness of optimization techniques. The statistical results of each optimizer, comprising the average, best, and worst cost values, are summarized in Table 14. As shown, the proposed MDBO achieved the lowest average and optimal cost, demonstrating its superior performance.

Table 14 Statistical results of the 24-unit system with considering PLs.

Figures 22 and 23 illustrate the convergence trajectories and boxplot representations of the outcomes produced by the different optimization algorithms under study. The proposed MDBO algorithm exhibited not only accelerated convergence but also robust and stable performance, consistently attaining the optimal solution for the CHPED problem.

Fig. 22
figure 22

Convergence behavior of cost by different optimizers for the 24-unit system considering PLs.

Fig. 23
figure 23

Boxplot of results of the 24-unit system considering PLs.

The results presented in Table 14 underscore the superior performance of the proposed MDBO algorithm, which achieved the lowest and best and average cost values among all evaluated optimizers. This outcome highlights the effectiveness of MDBO in solving large-scale, multivariable CHPED problems with nonlinear constraints. According to Tables 14 and 15, MDBO achieved a total cost of $57,803.47, outperforming all other compared algorithms. The percentage differences in cost relative to MDBO are as follows: DBO (0.747%), SCSO (2.006%), AVOA (1.292%), SCA (8.616%), HHO (2.309%), GWO (0.340%), LLCA (5.198%), ZOA (2.748%), WOA (3.438%), TLBO (0.351%), OTLBO (0.091%), RCGA-IMM (0.453%), ARO (0.104%), MGSO (0.033%), SGWO (0.419%), HBOA (0.329%), SNS (0.161%), OGSO (0.044%), GSA (0.548%), EMA (0.038%), GSO (0.549%), CPSO (3.235%), TVAC-PSO (0.548%), AFDB-ARO (0.0382%), IGA-NCM (0.391%), ACS-DEM (0.163%), IHT (0.259%), NDE (0.0427%), and IGSO (0.423%). These results demonstrate MDBO’s outstanding capability in delivering cost-effective and reliable solutions for complex CHPED systems.

Table 15 Statistical comparison of MDBO results with the other state-of-the-art techniques for 24-unit system with PLs.

The optimal CHPED schedules, accounting for power losses, were obtained using the various studied optimization algorithms, including the proposed MDBO, and are presented in Table 16. During the solution process for this large-scale CHPED system, no constraint violations were observed, and all operational limits were strictly adhered to. These results confirm the feasibility, accuracy, and robustness of all optimization methods evaluated, particularly the MDBO, which demonstrated high reliability in producing constraint-compliant solutions under complex system conditions.

Table 16 Optimal CHPED scheduling for the 24-unit system considering power losses.

Test system-4 (48-unit system)

The fourth studied test system consists of 48 generating units, including 26 power-only units, 12 CHP units, and 10 heat-only units. This configuration is required to satisfy an electrical demand of 4700 MW and a thermal demand of 2500 MWth. The parameters defining the cost functions are details are taken from 71. The objective of this test case is to minimize the total operating cost, with cost functions that account for VPLE and POZs. The simulations for this large-scale CHPED case were conducted and listed in Table 17, applying various optimization algorithms, including the proposed MDBO. This complex test case includes VPLE and POZs, making it a challenging benchmark for assessing the scalability and robustness of optimization techniques.

Table 17 Optimal CHPED scheduling for the 48-unit system considering VPLE and POZs.

The optimal CHPED schedules, accounting for VPLE and POZs, were obtained using the various studied optimization algorithms, including the proposed MDBO, and are presented in Table 17. During the solution process for this large-scale CHPED system, no constraint violations were observed, and all operational limits were strictly adhered to. These results confirm the feasibility, accuracy, and robustness of all optimization methods evaluated, particularly the MDBO, which demonstrated high reliability in producing constraint-compliant solutions under complex system conditions. Also, the presented results underscore the superior performance of the proposed MDBO algorithm, which achieved the lowest total cost value among all evaluated optimizers. This outcome highlights the effectiveness of MDBO in solving large-scale, multivariable CHPED problems with nonlinear constraints.

  • Finally, according to the results obtained of the standard of the CEC-2019 benchmark functions the MDBO has the best performance compared to SCSA, AVOA, SCA, HHO, GWO, LCA, ZOA, and WOA in terms of the statistical results of Tables 2 and 3. Furthermore, the MDBO has stable and speed convergence characteristics compared to the comparative algorithms as depicted in Figs. 2 and 3.

  • The MDBO is superior optimizer to solve the CHPED in which the minimum operating costs were obtained compared to the other optimization algorithms for the small, the medium and the large test systems. The minimum operation cost by MDBO for the 4-unit system is 9257.1 $. The minimum operation costs for 7-unit test system with VPLE is 10,091.92 $, the minimum cost with VPLE and PLs is 10,094.21 $ and, the minimum cost with VPLE, PLs, and POZs is 10,101.28 $. The minimum cost of 24-Unit System with 57,803.47 $. The minimum cost with 48-unit system is system considering VPLE and POZs is 117,952 $.

Conclusions

This study critically examined the capability of the Modified Dung Beetle Optimizer (MDBO) in addressing the Combined Heat and Power Economic Dispatch (CHPED) problem, incorporating practical operational constraints such as transmission power losses (PLs), valve-point loading effects (VPLEs), and prohibited operating zones (POZs). The MDBO was developed to surmount common shortcomings of traditional metaheuristic algorithms, notably premature convergence and stagnation in the search process. By effectively enhancing the balance between exploration and exploitation phases, the MDBO demonstrated superior optimization performance. Its effectiveness was rigorously tested on four benchmark systems of CHPED problem of varying complexity: a 4-unit, a 7-unit, a 24-unit, and a 48-unit configuration. Extensive comparative analyses were performed against a broad spectrum of contemporary optimization algorithms, including Whale Optimization Algorithm (WOA), Sand Cat Swarm Optimization (SCSO), Zebra Optimization Algorithm (ZOA), African Vultures Optimization Algorithm (AVOA), Grey Wolf Optimizer (GWO), Harris Hawks Optimization (HHO), Liver Cancer Algorithm (LCA), and the original Dung Beetle Optimizer (DBO). The findings revealed that MDBO consistently outperformed these approaches by achieving lower total operational costs, accelerated convergence rates, and entirely feasible solutions across all test cases. Further, the robustness and scalability of MDBO were substantiated through evaluations using benchmark functions from the CEC-2019 suite, affirming its efficacy as a potent and dependable optimization method suitable for both small- and large-scale CHPED applications. In future work, incorporating the demand of electric vehicles and energy storage systems can be included in solving the CHPED problem.