**3.2 Mathematical models of distribution networks**

Within the frame of this section, the mathematical models of a conventional and cyber-physical distribution network are described. The mathematical models are focusing on energy efficiency-related "green" objective functions, including energy consumption and greenhouse gas emission as the most important influencing factors of environmental impact. The mathematical model includes time, capacity, and energy-related constraints.

#### *3.2.1 Mathematical model of a conventional distribution network*

The objective function of the optimization problem is either the energy consumption or the real or virtual greenhouse gas emission. The energy consumption as objective function can be defined as follows in the case of conventional distribution:

$$EC^{CONV} = \sum\_{a=1}^{a\_{\text{max}}} EC\_a^{MD} + \sum\_{a=1}^{a\_{\text{max}}} EC\_a^{DC} \to \min. \tag{1}$$

where *ECCONV* is the energy consumption of the conventional distribution system, *ECMD <sup>a</sup>* is the energy consumption between the manufacturer cluster *a* and distribution cluster *a*, *ECDC <sup>a</sup>* is the energy consumption between the distribution cluster *a* and the consumers, *amax* is the number of independent distribution networks.

The energy consumption between the manufacturer cluster *a* and the distribution cluster *a* can be defined as follows:

*Supply Chain: A Modeling-Based Approach for Cyber-Physical Systems DOI: http://dx.doi.org/10.5772/intechopen.105527*

$$EC\_a^{MD} = \sum\_{a=1}^{a\_{max}} \varepsilon\_{v\_{au}} \left( q\_{v\_{au}} \right) \bullet l\_{aa}^{opt} \left( \Theta\_{au} \right) \tag{2}$$

where *v<sup>α</sup><sup>a</sup>* is the transportation vehicle assigned to route *α* of distribution system *a* in Tier1 between manufacturers and distribution centers, *αmaxa* is the number of distribution routes for distribution system *a* in Tier1 between manufacturers and distribution centers, ε*v<sup>α</sup>* is the energy consumption of transportation vehicle *v<sup>α</sup><sup>a</sup>* assigned to route *α* of distribution system *a* in Tier1 between manufacturers and distribution centers*, lopt <sup>α</sup><sup>a</sup>* is the length of the optimal distribution route *α* of distribution system *a* in Tier1 between manufacturers and distribution centers*,* which is a function of the Θ*<sup>α</sup><sup>a</sup>* set of distribution centers assigned to route *α* of distribution system *a* in Tier1 between manufacturers and distribution centers, and *qv<sup>α</sup><sup>a</sup>* is the current capacity of transportation vehicle assigned to route *α* of distribution system *a* in Tier1 between manufacturers and distribution centers*.*

The energy consumption between the distribution cluster *a* and consumers assigned to distribution center *a* can be defined as follows:

$$EC\_{a}^{DC} = \sum\_{\beta=1}^{\beta\_{max}} \varepsilon\_{v\_{\beta a}} \left( q\_{v\_{\beta a}} \right) \bullet l\_{\beta a}^{opt} \left( \Theta\_{\beta a} \right) \tag{3}$$

where *vβ<sup>a</sup>* is transportation vehicle assigned to route *β* of distribution system *a* in Tier2 between distribution centers and consumers, *βmaxa* is the number of distribution routes for distribution system *a* in Tier2 between distribution centers and consumers, ε*<sup>v</sup>β<sup>a</sup>* is the energy consumption of transportation vehicle *vβ<sup>a</sup>* assigned to route *β* of distribution system *a* in Tier2 between distribution centers and consumers*, lopt <sup>β</sup><sup>a</sup>* is the length of the optimal distribution route *β* of distribution system *a* in Tier2 distribution centers and consumers*,* which is a function of the Θ*β<sup>a</sup>* set of distribution centers assigned to route *β* of distribution system *a* in Tier2 between distribution centers and consumers, and *qv<sup>β</sup><sup>a</sup>* is the current capacity of transportation vehicle assigned to route *β* of distribution system *a* in Tier2 between distribution centers and consumers*.*

The second objective function is the greenhouse gas emission, which can be defined for the following GHGs: carbon dioxide, methane, nitrous oxide, and fluorinated gases. The GHG emission can be defined in the following way for the different GHGs in the case of conventional distribution:

$$\mathrm{EM}\_{\mathrm{MGHG}}^{\mathrm{CONV}} = \sum\_{a=1}^{a\_{\mathrm{max}}} \mathrm{EM}\_{\mathrm{MGHG}}^{\mathrm{MDa}} + \sum\_{a=1}^{a\_{\mathrm{max}}} \mathrm{EM}\_{\mathrm{MGHG}}^{\mathrm{DCa}} \to \min. \tag{4}$$

where *EMCONV MGHG* is the *GHG* emission of the conventional distribution system, *EMMDa MGHG* is the GHG emission of the vehicle assigned to the distribution operations between the manufacturer cluster *a* and distribution cluster *a, EMDCa MGHG* is the GHG emission of vehicles assigned to distribution operations between the distribution cluster *a* and the consumers, and *MGHG* ¼ ½ � *CO*2, *SO*2,*CO*, *HC*, *NOx*, *PM* is the matrix of greenhouse gases to be taken into consideration.

The emission between the manufacturer cluster *a* and the distribution cluster *a* can be defined as follows:

$$EM\_{MGHG}^{MDa} = \sum\_{a=1}^{a\_{max}} \Theta\_{MGHG}^{TIER1, \nu\_{au}} \bullet \varepsilon\_{\nu\_{au}} \left(q\_{\nu\_{au}}\right) \bullet l\_{aa}^{opt}(\Theta\_{aa}) \tag{5}$$

where ϑ*TIER*1,*vα<sup>a</sup> MGHG* is the specific GHG emission in the case of transportation vehicle assigned to route *α* of distribution system *a* in Tier1 between manufacturers and distribution centers*.*

The emission between the distribution cluster *a* and consumers assigned to distribution center *a* can be defined as follows:

$$\mathbf{E}\mathbf{M}\_{\mathrm{MGHG}}^{\mathrm{DCA}} = \sum\_{\beta=1}^{\beta\_{\mathrm{max}}} \boldsymbol{\mathfrak{G}}\_{\mathrm{MGHG}}^{\mathrm{TIER2},\nu\_{\beta\mathbf{a}}} \cdot \boldsymbol{\mathfrak{e}}\_{\nu\_{\beta\mathbf{a}}} \left(\boldsymbol{q}\_{\nu\_{\beta\mathbf{a}}}\right) \bullet \boldsymbol{l}\_{\beta\mathbf{a}}^{\mathrm{opt}} \left(\boldsymbol{\Theta}\_{\beta\mathbf{a}}\right) \tag{6}$$

where ϑ *TIER*2,*vβ<sup>a</sup> MGHG* is the specific GHG emission in the case of transportation vehicle assigned to route *β* of distribution system *a* in Tier2 between distribution centers and consumers*.*

As constraints, we can take the following into consideration: capacity of vehicles, capacity of loading and unloading equipment, capacity of distribution centers, time window for manufacturer, time window for customers, time window for 3PL providers in Tier1, time window for 3PL providers in Tier2, and available energy for electric vehicles.

Constraint 1a: We can define the upper limit of the loading capacity of transportation vehicles. It is not allowed to exceed this upper limit of loading capacity while assigning distribution tasks to the routes and scheduling the delivery tasks:

$$\forall \alpha, a: \text{ C}\_{v\_{\text{at}}} \ge \sum\_{i=1}^{i\_{\text{max}}} \mathbf{q}\_i \in \Psi\_{\text{at}} \tag{7}$$

where C*<sup>v</sup>α<sup>a</sup>* is the upper limit of loading capacity of the transportation vehicle assigned to route *α* of distribution system *a*, *imax* is the upper limit of customers' demands, q*<sup>i</sup>* is the volume or weight (capacity unit) of customers' demand *i*, Ψ*α<sup>a</sup>* is the set of customers' demands assigned to route *α* of distribution system *a.*

Constraint 2a: We can define the upper limit of the material-handling capacity of loading and unloading equipment. It is not allowed to exceed this upper limit of material handling capacity while assigning distribution tasks to the routes and scheduling the delivery tasks:

$$\forall \alpha, a: \ \mathcal{C}\_{\mathbf{x}\_{au}} \ge \sum\_{i=1}^{i\_{\max}} \mathbf{z}\_i \left(\mathbf{q}\_i \in \Psi\_{au}\right) \tag{8}$$

where C*<sup>z</sup>α<sup>a</sup>* is the upper limit of the material-handling capacity of the loading and unloading equipment assigned to delivery tasks of route *α* of distribution system *a*, z*<sup>i</sup>* is the required material handling capacity of customers demand *i.*

Constraint 3a: We can define the upper limit of the storage capacity of distribution centers. It is not allowed to exceed this upper limit by assigning manufacturers to distribution centers and distribution centers to customers:

$$\forall a: \text{ CW}\_a \ge \sum\_{i=1}^{i\_{\text{max}}} \sum\_{a=1}^{a\_{\text{max}}} \mathbf{q}\_{ia} \in \Psi\_{aa} \tag{9}$$

#### *Supply Chain: A Modeling-Based Approach for Cyber-Physical Systems DOI: http://dx.doi.org/10.5772/intechopen.105527*

where CW*<sup>a</sup>* is the storage capacity of the distribution center of distribution system *a*, q*i<sup>α</sup>* is the customers' demand *i* assigned to route *α* of distribution system *a.*

Constraint 4a: We can define a time window for the potential manufacturing process for each demand of customers. It is not allowed to exceed this lower and upper limit while assigning customers' demands to manufacturers and scheduling them:

$$\forall i, a: \quad \tau\_{ia}^{\text{MINm}} \le \tau\_{ia}^{m} \le \tau\_{ia}^{\text{MAXm}} \tag{10}$$

where *τMINm ia* is the lower limit of the time window for the manufacturing process for customers' demand i at the manufacturer of the distribution system a, *τMAXm ia* is the upper limit of the time window for the manufacturing process for customers' demand i at the manufacturer of the distribution system a, *τ<sup>m</sup> ia* is the scheduled manufacturing time for customers' demand i at the manufacturer of the distribution system a.

Constraint 5a: We can define a time window for the customers' demands. The manufactured products must be delivered within this predefined time window to the customers and it is not allowed to exceed this time window:

$$\forall i, a: \quad \pi\_{ia}^{\text{MINcd}} \le \pi\_{ia}^{cd} \le \pi\_{ia}^{\text{MAXcd}} \tag{11}$$

where *τMINcd ia* is the lower limit of the time window for delivering the manufactured product to customer *i* in the distribution system *a*, *τMAXcd ia* is the upper limit of the time window for delivering the manufactured product to customer *i* in the distribution system *a*, *τcd ia* is the scheduled delivery of manufactured product to customer *i* in the distribution system *a.*

Constraint 6a: The material handling operations can be performed by third-party logistics providers in the case of Tier1 and Tier 2. We can define an available time window of these 3PL providers and it is not allowed to exceed this time window while assigning and scheduling material handling tasks performed by the 3PL providers:

$$\forall i, a, \mu: \quad \tau\_{ia\mu}^{\text{MIN3PL}} \le \tau\_{ia\mu}^{\text{3PL}} \le \tau\_{ia\mu}^{\text{MAX3PL}} \tag{12}$$

where *τMIN*3*PL ia<sup>μ</sup>* is the lower limit of the time window of availability of third-party logistics provider for customers' demand *i* in distribution system *a* in Tier *μ*, *τMAX*3*PL ia<sup>μ</sup>* is the upper limit of the time window of availability of third-party logistics provider for customers' demand *i* in distribution system *a* in Tier *μ*, *τ*<sup>3</sup>*PL ia<sup>μ</sup>* is the scheduled logistics service for customers' demand *i* in distribution system *a* in Tier *μ*.

Constraint 7a: As a sustainability and energy efficiency-related constraint, we can define the available energy of transportation vehicles and other material handling equipment. For example, in the case of electric vehicles we can define the available capacity of batteries or the required reloading time:

$$\forall a, \alpha: \quad \varepsilon\_{v\_{au}} \left( q\_{v\_{au}} \in \Psi\_{\alpha t} \right) \bullet l\_{\alpha a}^{opt} \left( \Theta\_{\alpha t} \right) \leq E\_{v\_{au}}^{max} \tag{13}$$

where *Emax <sup>v</sup>α<sup>a</sup>* is the upper limit of available energy (capacity of a battery in the case of electric vehicles).

#### *3.2.2 Mathematical model of a cyber-physical distribution network*

In the case of a cyber-physical distribution system, where Industry 4.0 technologies make it possible to integrate the operation of the different distribution system within and between tiers the energy consumption can be computed in the following way:

$$EC^{CYB} = EC^{MD} + EC^{DC} \to \min.\tag{14}$$

where *ECCYB* is the energy consumption of the cyber-physical distribution system, which integrates all individual separated distribution systems of the conventional solution, *ECMD* is the energy consumption between manufacturers and distribution clusters, *ECDC* is the energy consumption between the distribution centers and consumers.

The energy consumption between manufacturers and distribution centers in Tier 1 can be defined as follows:

$$EC^{MD} = \sum\_{a=1}^{a\_{\text{max}}} \varepsilon\_{v\_a} \left( q\_{v\_a} \right) \bullet l\_a^{opt} \left( \Theta\_a \right) \tag{15}$$

where *v<sup>α</sup>* is the transportation vehicle assigned to route *α* in Tier1 between manufacturers and distribution centers, *αmax* is the total number of distribution routes for Tier1 between manufacturers and distribution centers, ε*<sup>v</sup><sup>α</sup>* is the energy consumption of transportation vehicle *v<sup>α</sup>* assigned to route *α* in Tier1 between manufacturers and distribution centers*, lopt <sup>α</sup>* is the length of the optimal distribution route *α* in Tier1 between manufacturers and distribution centers*,* which is a function of the Θ*<sup>α</sup>* set of distribution centers assigned to route *α* in Tier1 between manufacturers and distribution centers, and *qv<sup>α</sup>* is the current capacity of transportation vehicles assigned to route *α* in Tier1 between manufacturers and distribution centers*.*

The energy consumption between the distribution centers and consumers in Tier2 can be defined as follows:

$$EC^{DC} = \sum\_{\beta=1}^{\beta\_{\max}} \varepsilon\_{v\_{\beta}} \left( q\_{v\_{\beta}} \right) \bullet l\_{\beta}^{opt} \left( \Theta\_{\beta} \right) \tag{16}$$

where *v<sup>β</sup>* is the transportation vehicle assigned to route *β* in Tier2 between distribution centers and consumers, *βmax* is the number of distribution routes in Tier2 between distribution centers and consumers, ε*<sup>v</sup><sup>β</sup>* is the energy consumption of transportation vehicle *v<sup>β</sup>* assigned to route *β* in Tier2 between distribution centers and consumers*, lopt <sup>β</sup>* is the length of the optimal distribution route *β* in Tier2 between distribution centers and consumers*,* which is a function of the Θ*<sup>β</sup>* set of distribution centers assigned to route *β* in Tier2 between distribution centers and consumers, and *qv<sup>β</sup>* is the current capacity of transportation vehicles assigned to route *β* in Tier2 between distribution centers and consumers*.*

The transformation of the conventional distribution system into cyber-physical distribution is suitable from energy consumption point of view, if

$$\sum\_{a=1}^{a\_{\text{max}}} E \mathbf{C}\_a^{\text{MD}} + \sum\_{a=1}^{a\_{\text{max}}} E \mathbf{C}\_a^{\text{DC}} \gg E \mathbf{C}^{\text{MD}} + E \mathbf{C}^{\text{DC}} \tag{17}$$

In the case of a cyber-physical distribution system, the emission of greenhouse gases can be computed in the following way:

$$\rm EM\_{MGHG}^{CYB} = EM^{MD} + EM^{DC} \to \min. \tag{18}$$

where *EMCYB MGHG* is the GHG emission of the cyber-physical distribution system, which integrates all individual separated distribution systems of the conventional solution, *EMMD* is the GHG emission between manufacturers and distribution clusters, *EMDC* is the GHG emission between the distribution centers and consumers.

The GHG emission between manufacturers and distribution centers in Tier 1 can be defined as follows:

$$EM\_{MGHG}^{MD} = \sum\_{a=1}^{a\_{max}} \\$\_{MGHG}^{TIER1, v\_a} \bullet \varepsilon\_{v\_a} \left(q\_{v\_a}\right) \bullet l\_a^{opt}(\Theta\_a) \tag{19}$$

where ϑ*TIER*1,*v<sup>α</sup> MGHG* is the specific GHG emission in the case of transportation vehicles assigned to route *α* in Tier1 between manufacturers and distribution centers*.*

The emission between the distribution centers and consumers in Tier2 can be defined as follows:

$$\mathbf{E}\mathbf{M}\_{\mathrm{MGHG}}^{\mathrm{DC}} = \sum\_{\boldsymbol{\beta}=\mathbf{1}}^{\boldsymbol{\beta}\_{\mathrm{max}}} \boldsymbol{\mathfrak{s}}\_{\mathrm{MGHG}}^{\mathrm{TER2},\boldsymbol{\nu}\_{\boldsymbol{\beta}}} \bullet \mathbf{e}\_{\boldsymbol{\nu}\_{\boldsymbol{\beta}}} \left(\boldsymbol{q}\_{\boldsymbol{\nu}\_{\boldsymbol{\beta}}}\right) \bullet I\_{\boldsymbol{\beta}}^{\mathrm{opt}} \left(\boldsymbol{\Theta}\_{\boldsymbol{\beta}}\right) \tag{20}$$

where ϑ*TIER*2,*v<sup>β</sup> MGHG* is the specific GHG emission in the case of transportation vehicles assigned to route *β* in Tier2 between distribution centers and consumers*.*

The transformation of the conventional distribution system into cyber-physical distribution is suitable from GHG emission point of view, if

$$\sum\_{a=1}^{a\_{\text{max}}} \text{EM}\_{\text{MGHG}}^{\text{MDa}} + \sum\_{a=1}^{a\_{\text{max}}} \text{EM}\_{\text{MGHG}}^{\text{DCa}} \gg \text{EM}\_{\text{MGHG}}^{\text{MD}} + \text{EM}\_{\text{MGHG}}^{\text{DC}} \tag{21}$$

As constraints, we can take the following into consideration: capacity of vehicles, capacity of loading and unloading equipment, capacity of distribution centers, time window for manufacturer, time window for customers, time window for 3PL providers in Tier1, time window for 3PL providers for Tier2, available energy for electric vehicles.

Constraint 1b: We can define the upper limit of the loading capacity of transportation vehicles. It is not allowed to exceed this upper limit of loading capacity while assigning distribution tasks to the routes and scheduling the delivery tasks. The difference between the constraints *1a* and *1b* is that, while in the case of a conventional distribution network, customer demand can only be assigned to the transport vehicles within the given distribution network, in the case of a cyberphysical distribution system, any customer demand can be assigned to any transportation vehicle:

$$\forall a: \text{ C}\_{v\_a} \ge \sum\_{i=1}^{i\_{\text{max}}} \mathbf{q}\_i \in \Psi\_a \tag{22}$$

where Ψ*<sup>α</sup>* is the set of customers' demands assigned to route *α* in the cyber-physical distribution network*.*

Constraint 2b: We can define the upper limit of the material handling capacity of loading and unloading equipment. It is not allowed to exceed this upper limit of material-handling capacity while assigning distribution tasks to the routes and scheduling the delivery tasks. The difference between the constraints *2a* and *2b* is that, while in the case of a conventional distribution network, customer demand can only be assigned to the transport vehicles and related material handling equipment (loading and unloading equipment, packaging machines, labeling) within the given distribution network, in the case of a cyber-physical distribution system, any customer demand can be assigned to any material handling equipment:

$$\forall a, a: \text{ C}\_{x\_a} \ge \sum\_{i=1}^{i\_{\text{max}}} \mathbf{z}\_i \left( \mathbf{q}\_i \in \Psi\_a \right) \tag{23}$$

Constraint 3b: We can define the upper limit of the storage capacity of distribution centers. The difference between constraints 3a and 3b is that while in the case of the conventional distribution system the capacity of a distribution system depends on only the manufacturers and customers of the same distribution system, in the case of a cyber-physical distribution network all products produced by all manufacturers can be assigned to all distribution centers (warehouses):

$$\forall a: \text{ CW}\_a \ge \sum\_{i=1}^{i\_{\text{max}}} \sum\_{a=1}^{a\_{\text{max}}} \mathbf{q}\_{ia} \in \Psi\_a \tag{24}$$

where CW*<sup>a</sup>* is the storage capacity of the distribution center of distribution system *a*, q*i<sup>α</sup>* is the customers' demands *i* assigned to route *α* of distribution system *a.*

Constraint 4b: We can define a time window for the potential manufacturing process for each demand of customers. It is not allowed to exceed this lower and upper limit while assigning customers' demands to manufacturers and scheduling them. In this cyber-physical network, the time windows can be defined for all manufacturers of the whole network, while in the case of conventional distributions networks, the time windows are focusing on the manufacturers of separated distribution systems:

$$\forall i, a: \quad \tau\_{ia}^{\text{MINm}} \le \tau\_{ia}^{m} \le \tau\_{ia}^{\text{MAXm}} \tag{25}$$

where *τMINm ia* is the lower limit of the time window for the manufacturing process for customers' demand *i* at the manufacturer of the distribution system *a*, *τMAXm ia* is the upper limit of the time window for the manufacturing process for customers' demand *i* at the manufacturer of the distribution system *a*, *τ<sup>m</sup> ia* is the scheduled manufacturing time for customers' demand *i* at the manufacturer of the distribution system *a.*

Constraint 5b: We can define a time window for the customers' demands. The manufactured products must be delivered within this predefined time window to the customers and it is not allowed to exceed this time window. In this cyber-physical network, the time windows can be defined for all customers of the whole network, while in the case of conventional distribution networks, the time windows are focusing on the customers of separated distribution systems:

$$\forall i, a: \quad \tau\_{ia}^{\text{MINcd}} \le \tau\_{ia}^{cd} \le \tau\_{ia}^{\text{MAXcd}} \tag{26}$$

#### *Supply Chain: A Modeling-Based Approach for Cyber-Physical Systems DOI: http://dx.doi.org/10.5772/intechopen.105527*

where *τMINcd ia* is the lower limit of the time window for delivering the manufactured product to customer *i* in the distribution system *a*, *τMAXcd ia* is the upper limit of the time window for delivering the manufactured product to customer *i* in the distribution system *a*, *τcd ia* is the scheduled delivery of manufactured product to customer *i* in the distribution system *a.*

Constraint 6b: The material handling operations can be performed by third-party logistics providers in the case of Tier1 and Tier 2. We can define an available time window of these 3PL providers and it is not allowed to exceed this time window while assigning and scheduling material-handling tasks performed by the 3PL providers. In this case, the 3PL providers can perform all logistics operations in the cyber-physical distribution network, while in the case of conventional distribution systems, the 3PL providers of separated distribution systems can work uncoordinated:

$$\forall i, a, \mu: \quad \tau\_{ia\mu}^{\text{MIN3PL}} \le \tau\_{ia\mu}^{\text{3PL}} \le \tau\_{ia\mu}^{\text{MAX3PL}} \tag{27}$$

where *τMIN*3*PL ia<sup>μ</sup>* is the lower limit of the time window of availability of third-party logistics provider for customers' demand *i* in distribution system *a* in Tier *μ*, *τMAX*3*PL ia<sup>μ</sup>* is the upper limit of the time window of availability of third-party logistics provider for customers' demand *i* in distribution system *a* in Tier *μ*, *τ*<sup>3</sup>*PL ia<sup>μ</sup>* is the scheduled logistics service for customers' demand *i* in distribution system *a* in Tier *μ*.

Constraint 7b: As a sustainability and energy efficiency-related constraint, we can define the available energy of transportation vehicles and other material handling equipment. For example, in the case of electric vehicles we can define the available capacity of batteries or the required reloading time:

$$\forall a, \alpha: \quad \varepsilon\_{v\_{aa}} \left( q\_{v\_{aa}} \in \Psi\_{\alpha t} \right) \bullet l\_{\alpha a}^{opt} \left( \Theta\_{\alpha t} \right) \leq E\_{v\_{aa}}^{max} \tag{28}$$

where *Emax <sup>v</sup>α<sup>a</sup>* is the upper limit of available energy (capacity of a battery in the case of electric vehicles).

The decision variables of this NP-hard optimization problem are the followings:


• scheduling of logistics operations of 3PL provider in distribution center – customer relation (Tier 2).

To solve this integrated assignment, scheduling and routing problem of the green distribution network and heuristic algorithms can be used. In the literature, we can find a wide range of heuristic solutions to integrated assignment, scheduling and routing problems [54–56].
