 Previous Article in Journal
An End-to-End Formula Recognition Method Integrated Attention Mechanism
Previous Article in Special Issue

Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

# The Moving Firefighter Problem

1
Centro de Investigación en Computación del Instituto Politécnico Nacional, Mexico City 07738, Mexico
2
Consejo Nacional de Ciencia y Tecnología, Mexico City 03940, Mexico
3
Instituto Nacional de Astrofísica, Óptica y Electrónica, Coordinación de Ciencias Computacionales, Puebla 72840, Mexico
*
Author to whom correspondence should be addressed.
These authors contributed equally to this work.
Mathematics 2023, 11(1), 179; https://doi.org/10.3390/math11010179
Received: 16 November 2022 / Revised: 15 December 2022 / Accepted: 23 December 2022 / Published: 29 December 2022
(This article belongs to the Special Issue Optimisation Algorithms and Their Applications)

## Abstract

:
The original formulation of the firefighter problem defines a discrete-time process where a fire starts at a designated subset of the vertices of a graph G. At each subsequent discrete time unit, the fire propagates from each burnt vertex to all of its neighbors unless they are defended by a firefighter that can move between any pair of vertices in a single time unit. Once a vertex is burnt or defended, it remains in that state, and the process terminates when the fire can no longer spread. In this work, we present the moving firefighter problem, which is a generalization of the firefighter problem where the time it takes a firefighter to move from a vertex u to defend vertex v is determined by a function $τ$. This new formulation models situations such as a wildfire or a flood, where firefighters have to physically move from their current position to the location of an entity they intend to defend. It also incorporates the notion that entities modeled by the vertices are not necessarily instantaneously defended upon the arrival of a firefighter. We present a mixed-integer quadratically constrained program (MIQCP) for the optimization version of the moving firefighter problem that minimizes the number of burnt vertices for the case of general finite graphs, an arbitrary set $F ⊂ V$ of vertices where the fire breaks out, a single firefighter, and metric time functions $τ$.
MSC:
90-10; 90C35; 90C27; 90C11

## 1. Introduction

The firefighter problem was originally formulated by Bert Hartnell in 1995 . It defines a discrete-time model of a diffusive process (e.g., a fire, a flood, an infectious disease, information, a computer virus, or an invasive species) on a graph $G = ( V , E )$, where a fire breaks out at a set of vertices $F ⊂ V$. At each subsequent discrete time unit, the fire propagates from each burnt vertex to all of its neighbors unless they are defended by a firefighter. Once a vertex is burnt or defended, it remains in that state, and the process terminates when the fire can no longer spread. A solution to the problem defines the defending actions that have to be taken at each discrete time unit to optimally contain the spreading process by minimizing the number of burnt vertices or the time it takes to stop the diffusive process.
Over the years, the firefighter problem has gained growing relevance for its theoretical properties but also because it provides a simple model that can be used to study impactful phenomena such as the spreading and containment dynamics of viruses in social networks  and fires in oil terminals  and high-rise buildings .
Unfortunately, for the case of fighting actual fire outbreaks, the original formulation of the firefighter problem and its many variants and generalizations (e.g., [5,6,7,8,9,10,11,12,13,14,15,16,17,18]) fail to capture an important aspect that arises in more realistic scenarios, namely, that the process of transporting (or moving) a firefighter from her current location to defend an entity located at a different location may take a variable amount of time. In general, this time may be a function of the distance between the two locations and the particular properties of the terrain, the entity to be defended, and the firefighter herself. As a concrete example, when fighting a wildfire, any strategy has to consider the time it takes to move fire engines and perhaps heavy machinery to a given region and then defend that region by creating control lines containing no combustible material. This time may depend on many factors, such as the land topography and the type of fire engines. It is worth noting that designing efficient wildfire suppression strategies has become increasingly important. During the 2019/2020 bushfire season, the number of hectares burned in Australia surpassed 6.75 million , and 4.09 million hectares burned in the United States in 2020 . In 2021, more than 75 thousand wildfire outbreaks were detected in the Amazon Rainforest .
In this work, we introduce the moving firefighter problem, which is a generalization of the firefighter problem that incorporates a function $τ$ that determines the time it takes a firefighter to move from its current location at vertex $u ∈ V$ to defend another vertex $v ∈ V$. Similarly to the original formulation of the firefighter problem, in this generalization, we assume that the time it takes the fire to spread from a burnt vertex to its neighbors in the graph is constant.
We present a mixed-integer quadratically constrained program (MIQCP) for the optimized version of the moving firefighter problem that minimizes the number of burnt vertices for the case of general finite graphs, an arbitrary set $F ⊂ V$ of vertices where the fire breaks out, a single firefighter, and metric time functions $τ$. We characterized the performance of the proposed solution through experiments on random graphs.
The rest of the paper is organized as follows. Section 2 presents a review of the extensive body of work on the firefighter problem and of its generalization and variants. Section 3 presents the formulation of the moving firefighter problem and the concepts and notation that are used throughout the paper. In this section, we also establish that the moving firefighter problem is indeed a generalization of the original firefighter problem, and hence, that it belongs to the class of $NP$-hard problems. Section 4 presents the proposed exact solution. Section 5 presents the results of a series of experiments, and Section 6 presents our concluding remarks and future work.

## 2. Related Work

The firefighter problem has been extensively studied. It has been determined that it is $NP$-hard for bipartite graphs , for cubic graphs , for trees of maximum degree three  and of pathwidth three , for co-bipartite graphs , and for unit disk graphs . It has also been established that the problem is in P for caterpillars and P-trees , interval graphs, split graphs, permutation graphs, $P k$-free graphs for fixed k , and if the fire breaks out at a vertex of degree at most two, for graphs of maximum degree three .
For the case of $b ≥ 2$ firefighters, the problem is $NP$-complete for trees of maximum degree $b + 2$ and $NP$-hard for the optimization version that maximizes the number of saved (unburnt) vertices for trees of maximum degree $b + 3$ .
Regarding approximations, for the case of trees and a single firefighter, the greedy algorithm that every time selects the vertex that maximizes the number of protected vertices is a tight $1 / 2$-approximation [2,26]. There is also a ($1 − 1 / e$)-approximation algorithm for rooted trees based on an LP-relaxation and randomized rounding . The previous algorithm was used by Iwaikawa et al. to provide a 0.7144-approximation algorithm for ternary trees . The problem is not $n 1 − ϵ$-approximable on general graphs for any $ϵ ∈ ( 0 , 1 )$ unless $P = N P$ . More recently, Adjiashvili et al.  presented a polynomial-time approximation scheme (PTAS) for trees.
From a parameterized point of view, the problem is W-hard on general graphs for $b ≥ 1$ firefighters when parameterized by the number of saved vertices, protected vertices, and burned vertices .
Other generalizations of the firefighter problem include a version where the number of available firefighters at each time is not constant , a version where the objective is to protect a particular subset of the set of vertices $S ⊆ V$ [9,11], a version where the protection also propagates from each defended vertex to their non-burning neighbors [8,13], and a non-deterministic version where at each time the fire propagates to unprotected vertices with a given probability . There is also a fractional version where vertices can be partially burned and protected, and partially burned vertices can propagate their fractions of the fire to their undefended or partially defended neighbors . More recently, Coupechoux et al. introduced online versions of the firefighter and fractional firefighter problems where the number of available firefighters is revealed at each discrete time . The k-firefighter problem is another generalization defined in terms of a two-player game where the fire propagates to at most k vertices in each round with the objective of burning as many vertices as possible while the firefighter defends vertices to contain the spread of the fire [6,10].
The geometric firefighter problem [12,15,17] is the closest variation to the moving firefighter problem because it considers the speed with which barriers are constructed to contain the fire. In this variation, the fire starts at a point inside a simple polygon $P$ and circularly propagates at a constant speed. A firefighter sequentially builds a series of one-dimensional barriers at a constant speed, which can be different from the fire propagation speed, to contain the propagation of the fire. Barriers have to be built continuously before the fire reaches any of its points. The objective is to maximize the protected area of $P$, namely, the area separated from the fire by the barriers. Similarly to the original firefighter problem, the geometric firefighter problem assumes that the firefighter can be instantaneously transported from the last position of a recently constructed barrier to the origin of the next barrier in the solution.
In the traveling firefighter problem, also referred to as the $L 2$-TSP (traveling salesman problem), a firefighter has to extinguish a set of wildfires located at positions modeled by vertices. The distance between vertices is defined by a function $d : V × V → R ≥ 0$. A solution to this problem is a permutation of the vertices that minimize the total damage produced by the fires, which is a quadratic function of time elapsed from when the fires broke out to when the firefighter arrives .
Some other $NP$-hard problems that resemble the firefighter problem are the graph burning problem (GBP) [31,32,33] and the influence maximization problem (IMP) [34,35,36]. However, while they seek the rapid diffusion of information, the firefighter problem seeks diffusion containment. Nevertheless, very recently, the authors of  used the integer linear programming formulation (ILP) of the firefighter problem presented in  to derive the first exact solution to the graph burning problem.
Table 1 summarizes the main results discussed in this section.

## 3. The Moving Firefighter Problem

An instance of the moving firefighter problem ($M F P$) is defined as a 6-tuple $〈 G , F ,$$a , τ , f , T S 〉$, where $G = ( V , E )$ is a simple graph; $F ⊂ V$ is a subset of the vertices where the fire breaks out; a is the depot where the firefighters are initially stationed (also referred as anchor point); $τ : V ∪ { a } × V → R ≥ 0$ is a function that determines the time it takes a firefighter to move from either the depot a or a vertex $u ∈ V$ to any other vertex $v ∈ V$, and to defend v. f is the number of firefighters, and $T S > 0$ is a constant that defines the time it takes for the fire to spread from a burnt vertex $u ∈ V$ to its unprotected neighbors in G.
From the assumption that the fire spreads uniformly at a constant rate, we can organize the time into time slots of length $T S$. Each time slot defines a burning round, where at the beginning of each time slot, the fire propagates from burnt vertices to their neighbors in G unless they were defended by a firefighter. Once a vertex is burnt or defended, it remains in that state, and the process terminates when the fire can no longer spread. We will say that a vertex is protected if it is neither burning nor defended at the end of the process. The diffusive process starts at time slot 0 where only the vertices in F are burning.
For the case of a single firefighter, a feasible solution to the $M F P$ is a valid sequence $S$ of vertices defended by the firefighter. We say that a sequence $S = ( a , u 1 , … , u l )$ is valid if Equation (1) holds for each $i = 1 , 2 , … , l$. In Equation (1), $β S i$ is the time at which a vertex $u i$ would be burned if the defending sequence $S = ( a , u 1 , … , u l )$ were truncated to $S i = ( a , u 1 , … , u i − 1 )$.
The purpose of Equation (1) is to restrict the space of feasible solutions to that where the firefighter has enough time to defend every vertex in the sequence before the fire reaches them.
$τ ( a , u 1 ) + ∑ k = 1 i − 1 τ ( u k , u k + 1 ) ≤ β S i$
Figure 1 shows examples of an instance of the $M F P$ and of one of its solutions. The graph G is composed of the set of vertices $V = { v 0 , v 1 , v 2 , v 3 , v 4 , v 5 , v 6 , v 7 , v 8 , v 9 }$ and the set of edges $E = { ( v 0 , v 2 ) , ( v 1 , v 3 ) , ( v 2 , v 3 ) ,$$( v 2 , v 5 ) , ( v 3 , v 4 ) , ( v 3 , v 5 ) , ( v 3 , v 6 ) , ( v 4 , v 7 ) ,$$( v 5 , v 6 ) , ( v 5 , v 8 ) , ( v 6 , v 9 ) }$. The fire breaks out at vertices $F = { v 0 , v 1 }$, a single firefighter ($f = 1$) is initially stationed at the depot a, and $T S = 1$. The depot and the vertices in V are in the Euclidean plane. The number on top of the vertices indicates their shortest hop distance to their closest vertex in F, which in this example equals the smallest time slot in which they can burn. The figure also shows a feasible solution $S = ( a , v 5 , v 6 , v 7 )$ in which the firefighter moves from the depot a to defend vertex $v 5$, then moves to defend vertex $v 6$, and lastly moves to defend vertex $v 7$. For this defending sequence $S$, the value of $β S 1$ equals 2 because vertex $v 5$ burns at time 2 when the truncated protecting sequence $S 1 = ( a )$ is applied, $β S 2$ equals 2 because vertex $v 6$ burns at time 2 when the truncated protecting sequence $S 2 = ( a , v 5 )$ is applied, and similarly, $β S 3$ equals 3. $S$ is a valid sequence because $τ ( a , v 5 ) = 1.13 ≤ β S 1 = 2$, $τ ( a , v 5 ) + τ ( v 5 , v 6 ) = 1.99 ≤ β S 2 = 2$, and $τ ( a , v 5 ) + τ ( v 5 , v 6 ) + τ ( v 6 , v 7 ) = 2.81 ≤ β S 3 = 3$. The process ends after three burning rounds (at time slot three) because at that time, the fire can no longer spread. The value of this solution equals five because, at the end of the process, vertices $v 0 , v 1 , v 2 , v 3$, and $v 4$ are burnt.
For the instance of Figure 1, the firefighter cannot choose to defend vertex $v 3$ because $τ ( a , v 3 ) = 1.74 > β S 1 ′ = 1$ for sequence $S ′ = ( a , v 3 )$. It could defend $v 2$ because $τ ( a , v 2 ) = 0.80 < β S 1 ″ = 1$ for a sequence $S ″ = ( a , v 2 )$, but in this case no other vertex could be defended, giving a feasible solution $S ″ = ( a , v 2 )$ of value nine. In these examples, the process also ends at time slot 3 when the fire can no longer spread.
For the case of $f > 1$ firefighters, a feasible solution is a set of valid sequences $S = { S 1 , … , S f }$ of the vertices defended by each firefighter. In this case, $β S i$ has to be extended to compute the time in which a vertex $u i$ in a $S x ∈ S$ is burnt if none of the defending sequences in $S = { S 1 , … , S f }$ includes vertices protected at a time posterior to $τ ( a , u 1 ) + ∑ k = 1 i − 1 τ ( u k , u k + 1 )$ for $u k ∈ S x$.
The objective of the minimization version of the $M F P$ is to find a feasible solution that minimizes the number of burnt vertices at the end of the process.
The decision version of the moving firefighter problem for a single firefighter (1-MFP) is as follows.
Definition 1.
Decision version of the 1-MFP problem:Given an arbitrary instance $〈 G = ( V , E ) , F , a , τ , 1 , T S 〉$ of 1-MFP and an integer $k ≥ 1$, is there a valid sequence $S m o v i n g$ of vertices defended by the firefighter such that the number of burnt vertices at the end of the process is at most k?

#### 1-MFP Is NP-Complete

In this section, we show that 1-MFP is NP-complete via a polynomial-time reduction ($≤ P$) to the decision version of the firefighter problem for a single firefighter (1-FP), which can be defined as follows.
Definition 2.
Decision version of the 1-FP problem:Given an arbitrary instance $〈 G = ( V , E ) , F 〉$ of 1-FP, where $F ⊂ V$ is the set of vertices where the fire breaks out and an integer $k ≥ 1$, is there a sequence $S o r i g i n a l$ of vertices defended by the firefighter such that the number of burnt vertices at the end of the process is at most k?
Lemma 1.
Given an instance $〈 G , F 〉$ of 1-FP, an instance $〈 G ′ , F ′ , a , τ , 1 , T S = 1 〉$ of 1-MFP such that $G ′ = G$, $F ′ = F$, defending sequences $S o r i g i n a l = ( u 1 , … , u l )$ for the instance of 1-FP, $S m o v i n g = ( a , u 1 ′ , … , u l ′ )$ with $u i ′ = u i$ for each $u i ′ ∈ S m o v i n g$ for the instance of 1-MFP, and function $τ 1 ( u , v ) = 1$ $∀ u ≠ v$ with $u ∈ V ∪ { a }$, $v ∈ V$ and $τ 1 ( u , u ) = 0$ $∀ u ∈ V ∪ { a }$. The discrete time $t i$ in which a vertex $v i$ in $S o r i g i n a l = ( u 1 , … , u l )$ is defended equals the time $t i ′ = i$ in which its corresponding vertex $v i ′$ is defended in $S m o v i n g = ( a , u 1 ′ , … , u l ′ )$.
Proof of Lemma 1.
From the definition of $τ 1$, we can observe that the time $τ ( a , u 1 ′ ) + ∑ k = 1 i − 1 τ ( u k ′ , u k + 1 ′ )$ in which a vertex $u i ′ ∈ S m o v i n g$ is defended equals i. This is the same as the discrete-time in which the corresponding vertex $u i$ is defended by $S o r i g i n a l$, namely, i. □
Lemma 2.
Given an instance $〈 G , F 〉$ of 1-FP, an instance $〈 G ′ , F ′ , a , τ , 1 , T S = 1 〉$ of 1-MFP such that $G ′ = G$, $F ′ = F$, defending sequences $S o r i g i n a l = ( u 1 , … , u l )$ for the instance of 1-FP, $S m o v i n g = ( a , u 1 ′ , … , u l ′ )$ with $u i ′ = u i$ for each $u i ′ ∈ S m o v i n g$, for the instance of 1-MFP, and function $τ 1 ( u , v ) = 1$ $∀ u ≠ v$ with $u ∈ V ∪ { a }$, $v ∈ V$, and $τ 1 ( u , u ) = 0$ $∀ u ∈ V ∪ { a }$. A vertex $v ∈ G$ burns at discrete time t if and only if its corresponding vertex $v ′ ∈ G ′$ burns at the beginning of time slot t.
Proof of Lemma 2.
If a vertex $v ∈ G$ burns at discrete time t, it means that there is a shortest path P of length t, from a vertex $r ∈ F$ to v that does not contain any vertex in the truncated protecting sequence $S o r i g i n a l = ( u 1 , … , u t )$. Given that $G = G ′$, this shortest path P also exists in $G ′$ and does not contain vertices in $S m o v i n g = ( u 1 ′ , … , u t ′ )$. From Lemma 1, and because the fire propagates at the beginning of each time slot of length $T S = 1$, vertex $v ′$ has to burn at time t, a which equals the beginning of time slot t. A symmetric argument can be applied to show the other direction of the implication. □
Theorem 1.
1-MFP is NP-complete.
Proof of Theorem 1.
We first show that the 1-MFP is an NP. Given an arbitrary instance $〈 G , F , a , τ , 1 , T S 〉$, $k ≥ 1$, and a defending sequence $S = ( a , u 1 , … , u l )$, a certifier algorithm can check in polynomial-time if (1) holds for each $u i ∈ S$, given that the firefighter defends each $u i ∈ S$ at time $τ ( a , u 1 ) + ∑ k = 1 i − 1 τ ( u k , u k + 1 )$. Then, the certifier algorithm can execute, also in polynomial-time, the firefighting process to verify that the number of burnt vertices is, in fact, at most k.
Now, we show that 1-FP $≤ P$ 1-MFP. Given an arbitrary instance $〈 G , F 〉$ of 1-FP and an integer k, we construct an instance of 1-MFP as $〈 G ′ , F ′ , a , τ 1 , 1 , T S = 1 〉$ with $G ′ = G$, $F ′ = F$, and $τ 1 ( u , v ) = 1$ $∀ u ≠ v$ with $u ∈ V ∪ { a }$, $v ∈ V$ and $τ 1 ( u , u ) = 0$ $∀ u ∈ V ∪ { a }$. Constructing this instance of 1-MFP takes $O ( | V | 2 )$ steps.
Next, we claim that there is a defending sequence $S o r i g i n a l = ( u 1 , … , u l )$ for the instance of the 1-FP such that at most k vertices of G burn, if and only if there is a valid defending sequence $S m o v i n g ( a , u 1 ′ , … , u l ′ )$ with $u i ′ = u i$ for each $u i ′ ∈ S m o v i n g$, for the instance of the 1-MFP such that at most k vertices burn in $G ′$.
(⇒) We first show that $S m o v i n g = ( a , u 1 ′ , … , u l ′ )$ is valid. Let us proceed by contradiction and assume that $u j ∈ S m o v i n g$ is the vertex with the smallest index $j ∈ { 1 , … , l }$ such that $τ ( a , u 1 ) + ∑ k = 1 j − 1 τ ( u k , u k + 1 ) = j > β S j$. However, from Lemma 1, we saw that the time a vertex in $G ′$ is defended by $S m o v i n g$ equals the discrete time its corresponding vertex in G is defended by $S o r i g i n a l$. Since vertex $u j$ is defended at discrete time j in the original firefighter process, it can not be burning at time j, which means that there is no path from a vertex $r ∈ F$ to $u j$ of length j or shorter that does not contain a vertex in the truncated protecting sequence $( u 1 , … , u j − 1 )$. Since $G = G ′$, there is no such a path in $G ′$, and hence $β S j > j$, a contradiction. From Lemma 2, at the end of the burning process, exactly the same number of vertices are burning in both instances. Therefore, if at most k vertices of G burn, then at most k vertices burn in $G ′$.
(⇐) Since $S m o v i n g = ( a , u 1 ′ , … , u l ′ )$ is valid for the 1-MFP instance, from Lemma 1 and 2, we know that all the vertices in $S o r i g i n a l$ can be defended in the 1-FP instance. From Lemma 2, we also know that if at most k vertices of $G ′$ burn, then at most k vertices of G burn. □
Table 2 summarizes the notation used throughout the paper.

## 4. Mixed-Integer Quadratically Constrained Program for the 1-MFP

Expressions (2) to (23) define a mixed-integer quadratically constrained program (MIQCP) for the optimization version of the 1-MFP. This MIQCP is based on the integer linear program (ILP) for the original firefighter problem (FP). For simplicity, let us assume that vertices are labeled as ${ v 1 , v 2 , … , v n }$. In addition, let us consider the anchor point, a, as an isolated vertex in the graph. This way, the fire cannot catch this special vertex, and inconsistencies are not added to the formulation. As in the original FP, the proposed MIQCP for the 1-MFP requires an upper bound B on the number of burning rounds (or time slots) at which the diffusive process finishes. However, unlike the original FP, it also requires an upper bound D on the number of vertices that are defended within a single burning round. We will say that defending a vertex during a burning round defines a defense round within that burning round. The length of the defense rounds is a function of $τ$, and it is possible to have from 0 to D defense rounds in a given burning round.
The ILP for the original FP is relatively simple; it has $O ( n B )$ binary variables and $O ( n B Δ )$ constraints, where $Δ$ is the graph’s largest vertex degree. In contrast, our proposed MIQCP for the 1-MFP has $O ( n B D )$ binary variables, $O ( max { | E | D , n B D } )$ linear constraints, and $O ( n B D )$ quadratic constraints. Since B and D are upper bounded by n, the numbers of variables and constraints are upper bounded by $O ( n 3 )$. In addition, this MIQCP assumes that function $τ$ is normalized with respect to the length of the burning rounds (time slots), and hence that $T S = 1$.
$min ∑ i = 1 n b i , B$
$s . t . b i , j ≥ b i , j − 1 ∀ v i ∈ V , ∀ j ∈ [ 1 , B ]$
$d i , j ≥ d i , j − 1 ∀ v i ∈ V , ∀ j ∈ [ 1 , B ]$
$b i , j + d i , j ≤ 1 ∀ v i ∈ V , ∀ j ∈ [ 1 , B ]$
$b i , j + d i , j ≥ b k , j − 1 ∀ v i ∈ V , ∀ j ∈ [ 1 , B ] , ∀ v k ∈ N ( v i )$
$d j , i , 1 ′ ≥ d i , j − 1 ∀ v i ∈ V , ∀ j ∈ [ 1 , B ]$
$d j , i , D ′ = d i , j ∀ v i ∈ V , ∀ j ∈ [ 1 , B ]$
$d j , i , k ′ ≥ d j , i , k − 1 ′ ∀ v i ∈ V , ∀ j ∈ [ 1 , B ] , ∀ k ∈ [ 2 , D ]$
$p j , i , k ≥ d j , i , k ′ − d j , i , k − 1 ′ ∀ v i ∈ V , ∀ j ∈ [ 1 , B ] , ∀ k ∈ [ 2 , D ]$
$p j , i , 1 ≥ d j , i , 1 ′ − d i , j − 1 ∀ v i ∈ V , ∀ j ∈ [ 1 , B ]$
$∑ i = 1 n p j , i , k = 1 ∀ k ∈ [ 1 , D ] , ∀ j ∈ [ 1 , B ]$
$p j , i , k ≥ p j , i , k − 1 · 1 − ∑ l = 1 n d j , l , k ′ − d j , l , k − 1 ′ ∀ v i ∈ V , ∀ j ∈ [ 1 , B ] , ∀ k ∈ [ 2 , D ]$
$p j , i , 1 ≥ p j − 1 , i , D · 1 − ∑ l = 1 n d j , l , 1 ′ − d l , j − 1 ∀ v i ∈ V , ∀ j ∈ [ 1 , B ]$
$t j = t j − 1 + ∑ l = 1 n ∑ i = 1 n p j , i , 1 · τ l , i · p j − 1 , l , D ∀ j ∈ [ 1 , B ] + ∑ k = 2 D ∑ l = 1 n ∑ i = 1 n p j , i , k · τ l , i · p j , l , k − 1$
$t j ≤ j ∀ j ∈ [ 1 , B ]$
$where t 0 = 0$
$d a , 0 = 1$
$d i , 0 = 0 ∀ v i ∈ V \ { a }$
$b i , 0 = 1 i f i ∈ F 0 i f i ∉ F ∀ v i ∈ V$
$d 0 , i , k ′ = p 0 , i , k = d i , 0 ∀ v i ∈ V , ∀ k ∈ [ 1 , D ]$
$b i , j , d i , j , p j , i , k , d j , i , k ′ ∈ { 0 , 1 } ∀ v i ∈ V , ∀ j ∈ [ 1 , B ] , ∀ k ∈ [ 1 , D ]$
$t j ∈ R + ∀ j ∈ [ 1 , B ]$
The ILP for the FP problem only has two sets of binary variables, $b i , j$ and $d i , j$. Similarly, the main variables of the proposed MIQCP for the 1-MFP are $b i , j$ and $d i , j$ too. These variables report the state of each vertex i at the $j th$ burning round, where $i ∈ [ 1 , n ]$ and $j ∈ [ 1 , B ]$. Thus, if a vertex $v i$ is burnt at round j, then $b i , j = 1$; otherwise, $b i , j = 0$. If vertex $v i$ is burnt at round j, it is because of one of the following reasons: it was originally burnt at some previous round (Constraint (3)), or it is in the neighborhood of some previously burnt vertex (Constraint (6)). In case vertex $v i$ is defended at round j, then $d i , j = 1$; otherwise, $d i , j = 0$. A vertex that is defended at any round will remain in that state (Constraint (4)), and if a vertex is in the neighborhood of some previously burnt vertex, then it has to be either burned or defended (Constraint (6)). By Constraint (5), a vertex cannot be simultaneously burnt and defended. For further clarification, we can organize these variables in two $n × B$ matrices (see Equations (24) and (25)), where matrix d can be further extended to matrices d’$j$ and p$j$ (see Equations (26) and (27)), where $j ∈ [ 1 , B ]$.
$b = b 1 , 0 b 1 , 1 ⋯ b 1 , B b 2 , 0 b 2 , 1 ⋯ b 2 , B ⋮ ⋮ ⋱ ⋮ b n , 0 b n , 1 ⋯ b n , B$
$d = d 1 , 0 d 1 , 1 ⋯ d 1 , B d 2 , 0 d 2 , 1 ⋯ d 2 , B ⋮ ⋮ ⋱ ⋮ d n , 0 d n , 1 ⋯ d n , B$
Given that the 1-MFP allows sequentially defending many vertices within a burning round, we added a set of variables $d j , i , k ′$ in order to report the sequence of defended vertices, where $j ∈ [ 1 , B ]$, $i ∈ [ 1 , n ]$, and $k ∈ [ 1 , D ]$. In more detail, if vertex $v i$ is defended at the $k th$ defense round, within the $j th$ burning round, then $d j , i , k ′ = 1$; otherwise, $d j , i , k ′ = 0$. Notice that D is an upper bound on the number of defended vertices within one burning round. We can organize these variables into B matrices of size $n × D$. Thus, there is a matrix $d ′ j$ for each $j th$ burning round (see Equation (26)).
$d ′ j = d 1 , 1 ′ d 1 , 2 ′ ⋯ d 1 , D ′ d 2 , 1 ′ d 2 , 2 ′ ⋯ d 2 , D ′ ⋮ ⋮ ⋱ ⋮ d n , 1 ′ d n , 2 ′ ⋯ d n , D ′$
By Constraint (7), all vertices defended at the $( j − 1 ) th$ burning round stay defended at the beginning of the first defense round of the following burning round, which is reported in the first column of $d ′ j$. By Constraint (8), the state of the defended vertices at the end of the $j th$ burning round (column D of d’$j$) is copied into column j of matrix d. In other words, each column j of matrix d is a summary of what happens inside each matrix d’$j$. Similarly to Constraint (4), Constraint (9) indicates that once a vertex is defended at the $k th$ defense round of the $j th$ burning round, it will stay defended.
Constraints (10)–(12) describe the relationship between the binary variables $p j , i , k$ and variables $d j , i , k ′$. The goal of p$j$ is to report the last defended vertex at each defense round within each burning round. Notice that $p j , i , k = 1$ might mean two different things: vertex $v i$ has been defended precisely at the $k th$ defense round within burning round j (Constraints (10) and (11)), or vertex $v i$ is the last vertex defended at some previous round. Constraint (12) guarantees that exactly one vertex is the last defended at each defense round. Please note that Constraint (18) establishes that the anchor point a is defended at the beginning of the process. For convenience, we can organize these variables in a matrix p$j$ for each burning round (see Equation (27)).
Constraints (13) and (14) guarantee that the information about the last defended vertex is copied into the following columns of p. When a new vertex becomes defended, these constraints are deactivated by making the right-hand side equal to zero. In this case, the subsequent columns are no longer a copy of the previous ones; instead, the currently defended vertex is updated. Constraints (15) and (16) guarantee that the time $t j$ needed to carry out a sequence of defended vertices within the $j th$ burning round does not exceed the current number j of time slots of the diffusive process. By these two constraints, Constraints (3) and (5)–(14), which define the relationship between the defended vertices and the dynamics of the diffusive process, the firefighter cannot defend a vertex that the fire has already spread to (which is consistent with Equation (1)).
$p j = p 1 , 1 p 1 , 2 ⋯ p 1 , D p 2 , 1 p 2 , 2 ⋯ p 2 , D ⋮ ⋮ ⋱ ⋮ p n , 1 p n , 2 ⋯ p n , D$
The solution to an 1-MFP instance is obtained from the $d ′$ matrices by sequentially scanning them for the first time that a value of one appears in a row of one of such matrices. Remember that the first time that a value of one appears in row i of the matrix $d ′ j$ indicates that the vertex $v i$ is defended at burning round j, and hence, that it is part of the resulting defending sequence $S$. The ordering of the vertices in $S$ is obtained from the burning and defense rounds where they were defended.
For further clarification, Figure 2 shows the value of each variable in the solution of the example instance from Figure 1. In this example, we follow the convention of placing the anchor point in the last row of the matrices. Column $j = 0$ represents the process’ initial conditions where vertices $v 0$ and $v 1$ are the initial fire sources and the firefighter is located at the anchor point. The remaining columns of matrices $b$ and $d$ report the state of the vertices at the subsequent burning rounds. The resulting defending sequence $S$ equals $( a , v 5 , v 6 , v 7 )$ because the first value of one appears in the sixth row (the one corresponding to vertex $v 5$) of the first column of $d ′ 2$, the second value of one appears in the seventh row of $d ′ 3$, and the last value of one appears in the eighth row of the first column of $d ′ 3$. Time $t 1 = 0$ because no vertex is defended during the first burning round while $t 2 = 1.13 + 0.86 = 1.99$ because the firefighter moves from the anchor a to defend vertex $v 5$ and then from $v 5$ to defend $v 6$, which takes 1.99 units of time. Similarly, $t 3 = 2.81$ because that is the time needed to complete the whole defending sequence $S = ( a , v 5 , v 6 , v 7 )$, which is optimal for this instance.
Regarding a MIQCP for the MFP with more than one firefighter, we conjecture that the number of variables and constraints might increase by an order of f. The precise formulation is left as future work.

## 5. Experimental Performance Evaluation

In this section, we present the results of a series of experiments that characterize the performance of the proposed MIQCP for the 1-MFP. The purpose was twofold: first, to evaluate the impacts of the size of the graph, the scale of function $τ$, and the number of vertices where the fire breaks out on the value of the objective function and the MIQCP’s running time; second, to provide a set of optimally solved instances that can be used for future performance comparison analyses of heuristic or approximated solutions.
For these experiments, we generated instances $〈 G , F , a , τ , f , T S 〉$ of the 1-MFP, where the number of firefighters f equals one, the length of the time slots $T S$ also equals one, the number of initial fires $| F |$ is in ${ 1 , 3 }$, the graph $G = ( V , E )$ with $| V | = n ∈ { 10 , 20 , 30 , 40 }$ is randomly generated, and its vertices and the anchor point are placed uniformly at random inside a $1 × 1 × 1$ cube. To obtain a random graph G of size n, we generated a series of graphs $G ′ = ( V ′ , E ′ )$ of size $n ≤ | V ′ | < n + ⌈ n / 4 ⌉$ following the Erdős–Rényi model with $p = 2.5 / n$, until finding a $G ′$ with a connected component of size n which is used as G. Lastly, $τ$ is obtained from the Euclidean distances between the locations of the vertices and the anchor point.
We implemented the proposed MIQCP using Python and a commercial version of Gurobi 9.5.1 . Although there are other optimization solvers, not all of them can solve MIQCP problems. Gurobi and CPLEX  are among the best solvers with such capabilities. From them, we selected Gurobi because it is one of the fastest optimization solvers to date. All the experiments were executed using a computer running Ubuntu 20.04 on an Intel Core i7-6700 processor of 3.40 GHz with 32 GB of RAM.
For the results presented here, we used optimal values of the two hyperparameters introduced in the MIQCP—namely, the upper bound B for the number of time slots needed to complete the diffusive process and the upper bound D for the maximum number of vertices that can be defended in a single time slot. These optimal values were determined experimentally for each instance. As discussed in Section 4, the values of these upper bounds significantly impact the performance of the MIQCP because they determine the number of constraints. It is also important to highlight that underestimating these values precludes the MIQCP from finding optimal and even correct solutions.
Figure 3 presents the running times needed to solve instances with increasing numbers of vertices and initial fires, and when scaling function $τ$ by a factor $λ ∈ { 2 , 7 }$. The solid lines represent the average value computed over ten different random instances, and the shaded region represents the confidence interval for a confidence level of $95 %$. The results are as expected. From the figure, we can observe that the running time increases rapidly as the size of the graphs (n) increases because the numbers of linear ($O ( max { | E | D , n B D } )$) and quadratic ($O ( n B D )$) constraints increase as a function of n. We can also observe that the running time tends to be smaller with a larger number of initial burnt vertices ($| F |$) because the upper bound B on the number of time slots needed to complete the diffusive process also tends to be smaller as $| F |$ increases. The latter is because B is proportional to the length of the shortest paths from vertices in F to the remaining vertices in G. Lastly, the running time decreases as the value of $λ$ increases because the upper bound D on the number of vertices that can be defended in a single time slot decreases.
Figure 4 shows the average number of burnt vertices at the end of the diffusive processes when increasing the number of vertices, the number of initial fires, and the value of $λ$. As expected, the number of burnt vertices increases as the size of the graphs increases because, in general, the fire can propagate to a larger number of vertices. Increasing the number of initial fires increases the number of burnt vertices because the firefighter has to contain more than one diffusive process. This also reduces the objective function’s variability because having more than one initial fire makes the diffusive process less sensitive to the topological properties of the neighborhood where the fire breaks out. Lastly, the number of burnt vertices increases as the value of $λ$ increases because this has the effect of making the firefighter slower.
We performed experiments for graphs of size $n = 50$, but unfortunately, most of the executions did not end within a predefined time budget of 24 h, and in many cases, experienced memory crashes. This indicates a need for more scalable solutions for the MFP.

## 6. Conclusions

We presented the moving firefighter problem (MFP), a generalization of the original firefighter problem (FP) presented by Hartnell, which incorporates a function $τ$ that determines the time it takes a firefighter to move from vertex u to vertex v in the input graph to defend v. We argue that this generalization allows modeling more realistic situations where the time needed to defend an entity modeled by a vertex is not the same for all the entities and where there is either a physical or logical distance between each pair of entities. This new formulation has practical applications for studying the spread and containment dynamics in networks.
Using polynomial time reduction from the decision version of the original firefighter problem for a single firefighter 1-FP, we showed that the decision version of the moving firefighter problem for a single firefighter 1-MFP is indeed a generalization of the 1-FP, and hence, that it belongs to the NP-complete class of problems.
We presented a mixed-integer quadratically constrained program (MIQCP) for the optimization version of the 1-MFP with metric functions $τ$ that have $O ( n B D )$ binary variables, $O ( B )$ real-valued variables, $O ( max { | E | D , n B D } )$ linear constraints, and $O ( n B D )$ quadratic constraints. B and D are upper bounds to the numbers of burning and defense rounds, respectively. To empirically characterize the performance of the MIQCP, we solved 160 randomly generated instances. The results revealed that the running time of the MIQCP strongly depends on finding adequate values for B and D.
Future work includes designing scalable solutions for the 1-MFP, solutions for instances with more than one firefighter, and solutions specifically tailored for particular topologies such as trees. We also intend to design approximation algorithms and characterize the approximability of the MFP.

## Author Contributions

Conceptualization, B.R.G.-D.-L.-P., J.G.-D., R.M.-M. (Rolando Menchaca-Méndez), M.A.M.-M., R.M.-M. (Ricardo Menchaca-Méndez) and O.A.G.-D.-L.-P.; Methodology, B.R.G.-D.-L.-P., J.G.-D., R.M.-M. (Rolando Menchaca-Méndez), M.A.M.-M., R.M.-M. (Ricardo Menchaca-Méndez) and O.A.G.-D.-L.-P.; Software, B.R.G.-D.-L.-P., J.G.-D., M.A.M.-M. and O.A.G.-D.-L.-P.; Validation, R.M.-M. (Ricardo Menchaca-Méndez); Formal analysis, B.R.G.-D.-L.-P., J.G.-D., R.M.-M. (Rolando Menchaca-Méndez), M.A.M.-M., R.M.-M. (Ricardo Menchaca-Méndez) and O.A.G.-D.-L.-P.; Writing—original draft, B.R.G.-D.-L.-P., J.G.-D., R.M.-M. (Rolando Menchaca-Méndez), M.A.M.-M., R.M.-M. (Ricardo Menchaca-Méndez) and O.A.G.-D.-L.-P.; Writing—review & editing, B.R.G.-D.-L.-P., J.G.-D., R.M.-M. (Rolando Menchaca-Méndez), M.A.M.-M., R.M.-M. (Ricardo Menchaca-Méndez) and O.A.G.-D.-L.-P.; Visualization, B.R.G.-D.-L.-P., J.G.-D. and O.A.G.-D.-L.-P.; Supervision, R.M.-M. (Rolando Menchaca-Méndez) and R.M.-M. (Ricardo Menchaca-Méndez); Project administration, R.M.-M. (Rolando Menchaca-Méndez). All authors have read and agreed to the published version of the manuscript.

## Funding

This research was funded by the “Consejo Nacional de Ciencia y Tecnología” of México and the “Instituto Politécnico Nacional”.

## Data Availability Statement

The source code used in Section 5 is available at https://github.com/BrunoGupa/MovingFirefighterProblem. The same repository contains the specific instances and their corresponding optimal solutions that were used to obtain the results presented in Section 5.

## Conflicts of Interest

The authors declare that they have no conflict of interest.

## References

1. Hartnell, B. Firefighter! an application of domination. In Proceedings of the the 24th Manitoba Conference on Combinatorial Mathematics and Computing, University of Manitoba, Winnipeg, ON, Canada, 30 September–2 October 1994. [Google Scholar]
2. Finbow, S.; MacGillivray, G. The Firefighter Problem: A survey of results, directions and questions. Australas. J. Comb. 2009, 43, 57–78. [Google Scholar]
3. Khakzad, N. A graph theoretic approach to optimal firefighting in oil terminals. Energies 2018, 11, 3101. [Google Scholar] [CrossRef][Green Version]
4. Wang, K.; Yuan, Y.; Chen, M.; Lou, Z.; Zhu, Z.; Li, R. A Study of Fire Drone Extinguishing System in High-Rise Buildings. Fire 2022, 5, 75. [Google Scholar] [CrossRef]
5. Fogarty, P. Catching the Fire on Grids. Master’s Thesis, Department of Mathematics, University of Vermont, Burlington, VT, USA, 2003. [Google Scholar]
6. Develin, M.; Hartke, S.G. Fire containment in grids of dimension three and higher. Discret. Appl. Math. 2007, 155, 2257–2268. [Google Scholar] [CrossRef][Green Version]
7. Ng, K.L.; Raff, P. A generalization of the firefighter problem on Z × Z. Discret. Appl. Math. 2008, 156, 730–745. [Google Scholar] [CrossRef][Green Version]
8. Anshelevich, E.; Chakrabarty, D.; Hate, A.; Swamy, C. Approximation algorithms for the firefighter problem: Cuts over time and submodularity. In Proceedings of the International Symposium on Algorithms and Computation; Springer: Berlin, Germany, 2009; pp. 974–983. [Google Scholar]
9. King, A.; MacGillivray, G. The firefighter problem for cubic graphs. Discret. Math. 2010, 310, 614–621. [Google Scholar] [CrossRef][Green Version]
10. Bonato, A.; Messinger, M.E.; Prałat, P. Fighting constrained fires in graphs. Theor. Comput. Sci. 2012, 434, 11–22. [Google Scholar] [CrossRef][Green Version]
11. Bazgan, C.; Chopin, M.; Ries, B. The firefighter problem with more than one firefighter on trees. Discret. Appl. Math. 2013, 161, 899–908. [Google Scholar] [CrossRef]
12. Klein, R.; Levcopoulos, C.; Lingas, A. Approximation algorithms for the geometric firefighter and budget fence problems. In Proceedings of the Latin American Symposium on Theoretical Informatics; Springer: Berlin, Germany, 2014; pp. 261–272. [Google Scholar]
13. Anshelevich, E.; Chakrabarty, D.; Hate, A.; Swamy, C. Approximability of the firefighter problem. Algorithmica 2012, 62, 520–536. [Google Scholar] [CrossRef]
14. Michalak, K.; Knowles, J.D. Simheuristics for the multiobjective nondeterministic firefighter problem in a time-constrained setting. In Proceedings of the European Conference on the Applications of Evolutionary Computation; Springer: Berlin, Germany, 2016; pp. 248–265. [Google Scholar]
15. Klein, R.; Levcopoulos, C.; Lingas, A. Approximation algorithms for the geometric firefighter and budget fence problems. Algorithms 2018, 11, 45. [Google Scholar] [CrossRef][Green Version]
16. Coupechoux, P.; Demange, M.; Ellison, D.; Jouve, B. Firefighting on trees. Theor. Comput. Sci. 2019, 794, 69–84. [Google Scholar] [CrossRef]
17. Zambon, M.J.; de Rezende, P.J.; de Souza, C.C. Solving the geometric firefighter routing problem via integer programming. Eur. J. Oper. Res. 2019, 274, 1090–1101. [Google Scholar] [CrossRef]
18. Farhadi, M.; Toriello, A.; Tetali, P. The Traveling Firefighter Problem. In Proceedings of the SIAM Conference on Applied and Computational Discrete Algorithms (ACDA21), Philadelphia, PA, USA, 19–21 July 2021; pp. 205–216. [Google Scholar]
19. Granwal, L. Area of Bushfire Damage in Australia 2020 by Land Type. 2022. Available online: https://www.statista.com/statistics/1093799/australia-bushfire-damage-area-by-land-type/ (accessed on 14 April 2022).
20. Sönnichsen, N. Acres Burned by Wildfires in the United States from 1983 to 2020. 2021. Available online: https://www.statista.com/statistics/203990/area-of-acres-burnt-due-to-wildland-fires-in-the-us/ (accessed on 14 April 2022).
21. Alves, B. Number of Wildfires in Brazilian Biomes in 2021, by Type of Biome. 2022. Available online: https://www.statista.com/statistics/1044209/number-wildfires-brazil-biome/ (accessed on 14 April 2022).
22. MacGillivray, G.; Wang, P. On the firefighter problem. JCMCC J. Comb. Math. Comb. Comput. 2003, 47, 57–78. [Google Scholar]
23. Chlebíková, J.; Chopin, M. The firefighter problem: Further steps in understanding its complexity. Theor. Comput. Sci. 2017, 676, 42–51. [Google Scholar] [CrossRef][Green Version]
24. Fomin, F.V.; Heggernes, P.; van Leeuwen, E.J. The firefighter problem on graph classes. Theor. Comput. Sci. 2016, 613, 38–50. [Google Scholar] [CrossRef]
25. Finbow, S.; King, A.; MacGillivray, G.; Rizzi, R. The firefighter problem for graphs of maximum degree three. Discret. Math. 2007, 307, 2094–2105. [Google Scholar] [CrossRef][Green Version]
26. Hartnell, B.; Li, Q. Firefighting on Trees: How Bad is the Greedy Algorithm? In Proceedings of the Thirty-First Southeastern International Conference on Combinatorics, Graph Theory and Computing. Congressus Numerantium 145, Boca Raton, FL, USA, 11 September 2000; pp. 187–192. [Google Scholar]
27. Cai, L.; Verbin, E.; Yang, L. Firefighting on trees: (1- 1/e)–approximation, fixed parameter tractability and a subexponential algorithm. In Proceedings of the International Symposium on Algorithms and Computation; Springer: Berlin, Germany, 2008; pp. 258–269. [Google Scholar]
28. Iwaikawa, Y.; Kamiyama, N.; Matsui, T. Improved approximation algorithms for firefighter problem on trees. IEICE Trans. Inf. Syst. 2011, 94, 196–199. [Google Scholar] [CrossRef][Green Version]
29. Adjiashvili, D.; Baggio, A.; Zenklusen, R. Firefighting on trees beyond integrality gaps. ACM Trans. Algorithms (TALG) 2018, 15, 1–33. [Google Scholar]
30. Bazgan, C.; Chopin, M.; Cygan, M.; Fellows, M.R.; Fomin, F.V.; Van Leeuwen, E.J. Parameterized complexity of firefighting. J. Comput. Syst. Sci. 2014, 80, 1285–1297. [Google Scholar] [CrossRef]
31. Bonato, A.; Janssen, J.; Roshanbin, E. Burning a graph as a model of social contagion. In Proceedings of the International Workshop on Algorithms and Models for the Web-Graph; Springer: Berlin, Germany, 2014; pp. 13–22. [Google Scholar]
32. Bessy, S.; Bonato, A.; Janssen, J.; Rautenbach, D.; Roshanbin, E. Burning a graph is hard. Discret. Appl. Math. 2017, 232, 73–87. [Google Scholar] [CrossRef]
33. García-Díaz, J.; Pérez-Sansalvador, J.C.; Rodríguez-Henríquez, L.M.X.; Cornejo-Acosta, J.A. Burning graphs through farthest-first traversal. IEEE Access 2022, 10, 30395–30404. [Google Scholar] [CrossRef]
34. Kempe, D.; Kleinberg, J.; Tardos, É. Maximizing the spread of influence through a social network. In Proceedings of the Proceedings of the Ninth ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, Washington, DC, USA, 24–27 August 2003; pp. 137–146. [Google Scholar]
35. Banerjee, S.; Jenamani, M.; Pratihar, D.K. A survey on influence maximization in a social network. Knowl. Inf. Syst. 2020, 62, 3417–3455. [Google Scholar] [CrossRef][Green Version]
36. López-García, Á.O.; Rodríguez-Gómez, G.; López-López, A. A Physarum-Inspired Approach for Influence Maximization. In Proceedings of the International Conference on Metaheuristics and Nature Inspired Computing; Springer: Berlin, Germany, 2021; pp. 18–32. [Google Scholar]
37. García-Díaz, J.; Rodríguez-Henríquez, L.M.X.; Pérez-Sansalvador, J.C.; Pomares-Hernández, S.E. Graph Burning: Mathematical Formulations and Optimal Solutions. Mathematics 2022, 10, 2777. [Google Scholar] [CrossRef]
38. QMKPy: A Python Testbed for the Quadratic Multiple Knapsack Problem. arXiv 2022, arXiv:2211.17222.
39. A two-stage algorithm for the Virtual Network Embedding problem. In Proceedings of the 2021 IEEE 46th Conference on Local Computer Networks (LCN), Edmonton, AB, Canada, 4–7 October 2021.
Figure 1. Example of an instance of the MFP and one of its solutions.
Figure 1. Example of an instance of the MFP and one of its solutions.
Figure 2. State of the matrices defined by the MIQCP for the optimal solution of the instance defined in Figure 1. Here, $T S = 1$, $B = 3$, and $D = 2$.
Figure 2. State of the matrices defined by the MIQCP for the optimal solution of the instance defined in Figure 1. Here, $T S = 1$, $B = 3$, and $D = 2$.
Figure 3. Running time with one initial fire (left) and three initial fires (right). The x axis shows the number of vertices in the input graph, and the y axis shows the running time in seconds. The solid lines represent the average values over ten random instances, and the shaded regions are the confidence intervals for a confidence level of $95 %$.
Figure 3. Running time with one initial fire (left) and three initial fires (right). The x axis shows the number of vertices in the input graph, and the y axis shows the running time in seconds. The solid lines represent the average values over ten random instances, and the shaded regions are the confidence intervals for a confidence level of $95 %$.
Figure 4. Numbers of burnt vertices with one initial fire (left) and three initial fires (right). The x axis shows the number of vertices in the input graph, and the y axis shows the number of burnt vertices at the end of the process. The solid lines represent the average values over ten random instances, and the shaded regions are the confidence intervals for a confidence level of $95 %$.
Figure 4. Numbers of burnt vertices with one initial fire (left) and three initial fires (right). The x axis shows the number of vertices in the input graph, and the y axis shows the number of burnt vertices at the end of the process. The solid lines represent the average values over ten random instances, and the shaded regions are the confidence intervals for a confidence level of $95 %$.
Table 1. Summary of related work.
Table 1. Summary of related work.
ReferenceContributions
Hartnell introduces the Firefighter Problem (FP).
[9,11,22,23,24]The FP is NP-hard for different graph families.
[22,24,25]Instances where the FP is in P.
[8,26,27,28,29]Approximation results for the FP.
The FP is W-hard on general graphs with more than one firefighter.
Presents an integer linear program (ILP) for the FP.
Presents a version of the FP with a variable number of firefighters.
[9,11]Present the S-Fire version of the FP, which aims to protect a subset of the vertices.
[8,13]A version of the FP where the protection propagates from defended nodes.
Version of the FP with nondeterministic fire propagation.
Introduces the Fractional Firefighter Problem.
An Online version of the Fractional Firefighter Problem.
[6,10]Examine a two-player version of the FP called the k-Firefighter.
[12,15,17]The Geometric Firefighter Problem.
Presents the Traveling Firefighter Problem ($L 2$-TSP)
[31,32,33]Investigate the relation between the FP and the Graph Burning Problem.
Table 2. Summary of notation.
Table 2. Summary of notation.
 $G = ( V , E )$ Input graph. F Set of vertices where the fire breaks out. a Firefighters’ depot or anchor point. $τ$ Travel time function. f Number of firefighters. $T S$ Length of the time slots (burning round). $〈 G , F ,$$a , τ , f , T S 〉$ Instance of the 1-MFP. $〈 G , F 〉$ Instance of the 1-FP. $S = ( a , u 1 , … , u l )$ Defending sequence. $β S i$ Time when vertex $u i$ burns, given the truncated defending sequence $S i = ( a , u 1 , … , u i − 1 )$. $S = { S 1 , … , S f }$ Set of defending sequences for $f > 1$. B Upper bound on the number of burning rounds (or time slots). D Upper bound on the number of vertices defended within a single burning round. $b i , j$ Binary variable that indicates whether $v i$ is burning at the j-th burning round. $d i , j$ Binary variable that indicates whether $v i$ is defended at the j-th burning round. $d j , i , k ′$ Binary variable that indicates whether $v i$ is defended at the k-th defense round of the j-th burning round. $p j , i , k$ Binary variable that indicates whether $v i$ was the last defended vertex at the k-th defense round of the j-th burning round. $t j$ Continuous variable that indicates the time needed to carry out a defending sequence within the $j$-th burning round. $b$ $n × B$ matrix that contains the $b i , j$ binary variables. $d$ $n × B$ matrix that contains the $d i , j$ binary variables. $d ′ j$ $n × D$ matrix that contains the $d j , i , k ′$ binary variables. $p j$ $n × D$ matrix that contains the $p j , i , k$ binary variables.
 Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

## Share and Cite

MDPI and ACS Style

Gutiérrez-De-La-Paz, B.R.; García-Díaz, J.; Menchaca-Méndez, R.; Montenegro-Meza, M.A.; Menchaca-Méndez, R.; Gutiérrez-De-La-Paz, O.A. The Moving Firefighter Problem. Mathematics 2023, 11, 179. https://doi.org/10.3390/math11010179

AMA Style

Gutiérrez-De-La-Paz BR, García-Díaz J, Menchaca-Méndez R, Montenegro-Meza MA, Menchaca-Méndez R, Gutiérrez-De-La-Paz OA. The Moving Firefighter Problem. Mathematics. 2023; 11(1):179. https://doi.org/10.3390/math11010179

Chicago/Turabian Style

Gutiérrez-De-La-Paz, Bruno R., Jesús García-Díaz, Rolando Menchaca-Méndez, Mauro A. Montenegro-Meza, Ricardo Menchaca-Méndez, and Omar A. Gutiérrez-De-La-Paz. 2023. "The Moving Firefighter Problem" Mathematics 11, no. 1: 179. https://doi.org/10.3390/math11010179

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.