1 Introduction
Importing formal methods in connected fields.
Formal methods can help providing algorithmic solutions for control design. The electricvehicle (EV) charging problem is an example of such an application area. This problem, usually presented as a control problem (see eg. [5]), can actually be modelled using Markov decision processes (MDP) [12, 16, 14]
. Probabilities provide a way to model the nonflexible part of the energy network (consumption outside EV, for which large databases exist—and from which precise statistics can be extracted); we can then express an upper bound on the peak load as a safety condition (encoded as a reachability condition in our finitehorizon model), the constraint on the charging of all vehicles as a quantitative reachability objective, and various optimization criteria (e.g. minimizing the ageing of distribution transformers, or the energy price) as optimization of random cost variables.
Due to the specific form of the constructed model (basically acyclicity of the model), an adhoc method could be implemented using the tool PRISM, yielding interesting practical results as reported in [14] and in a forthcoming paper. However, the computability of an optimal strategy in a general MDP, as well as the corresponding decision problem, was unexplored.
Markov decision processes.
MDPs have been studied for long [18, 13]. An MDP is a finitestate machine, on which a kind of game is played as follows. In each state, several decisions (a.k.a. actions) are available, each yielding a distribution over possible successor states. Once an action is selected, the next state is chosen probabilistically, following the distribution corresponding to the selected action. The game proceeds that way ad infinitum, generating an infinite play. The way actions are chosen is according to a strategy (also called policy in the context of MDPs). Rewards and/or costs can be associated to each action or edge, and various rules for aggregating individual rewards and costs encountered along a play can be applied to obtain various payoff functions. Examples of payoff functions include:

sum up all the encountered costs (or rewards) along a play, until reaching some target (finite if the target is reached, infinite otherwise)—this is the socalled truncatedsum payoff;

sum up all the encountered costs (or rewards) along a play with a discount factor at each step—this is the socalled discountedsum payoff;

average over the encountered costs (or rewards) along a play—this is the socalled meanpayoff.
Those payoff functions have been extensively studied in the literature; discountedsum and meanpayoff have been shown to admit optimal memoryless and deterministic strategies, which can be computed using linear programming, yielding a polynomialtime algorithm. Alternative methods, such as value iteration or policy improvement, can be used in practice. On the other hand, the
shortestpath problem, which aims at minimizing the truncatedsum, has been fully understood only recently [2]: one can decide in polynomial time as well whether the shortestpath is finite, or whether it is equal to (if one cannot ensure reaching the target almostsurely), or whether it can be smaller than any arbitrary small number (if a negative loop can be enforced—note that in the context of stochastic systems, such a statement may be misleading, but it corresponds to a rough intuition), and corresponding strategies can be computed.Multiconstrained problems in MDPs.
The paradigm of multiconstrained objectives in stochastic systems in general, and in MDPs in particular, has recently arisen. It allows to express various (quantitative or qualitative) properties over the model, and to synthesize strategies accordingly. This new field of research is very rich and ambitious, with various types of objective combinations (see for instance [3, 19] for recent overviews). For recent developments on MDPs, one can cite:

Pareto curves, or percentile queries, of multiple quantitative objectives: given several payoff functions, evaluate which tradeoff can be made between the probabilities, or the expectations, of the various payoff functions. In [9, 7, 10], solutions based on linear programming are provided for meanpayoff objectives. The percentilequery problem for various quantitative payoff functions is studied in [20].

probability of conjunctions of objectives: given several payoff functions, evaluate the probability that all constraints are satisfied. This problem is studied in [15] for reachability (that is, for the truncatedsum payoff function), a lower bound is proved for that problem, already with a single payoff function.
Our contributions.
The general multiconstrained problem, arising from the EVcharging problem as modelled in [14], takes as an input an MDP with two weights, and , and requires the existence (and synthesis) of a strategy ensuring that some (absorbing) target state be reached, with a percentile constraint on the truncated sum of (lower bound parameterized by ), and an expectation constraint on the truncated sum of . The initial EVcharging problem corresponds to the instance of that problem when , where represents the energy that is used for charging and represents the ageing of the transformer.
As defined above, our problem integrates both the “beyond worstcase” paradigm of [8], and percentile queries as in [10] (mixing probabilities and expectations). While in [10] linear programs are used for solving percentile queries (heavily relying on the fact that meanpayoff objectives are tail objectives), we need different techniques since the truncatedsum payoff is very much prefixdependent; actually, the lower bound of [15] immediately applies here as well (even without a constraint on the expectation of ). We develop here a methodology to describe the cartography of the problem, that is, the set of values of the parameter for which the problem has a solution. Our approach is based on two sequences of optimization problems which, in some cases we characterize, allow to have the (almost) full picture. We then discuss computability issues.
2 Preliminary definitions
Let be a finite set. We write for the set of distributions over , that is, the set of functions such that . A distribution over is Dirac if for some .
2.1 Definition of the model
In this paper, we mainly focus on doublyweighted Markov decision processes, but the technical developments mainly rely on simplyweighted Markov decision processes. We therefore define the setting with an arbitrary number of weights.
Let . A weighted Markov decision process (wMDP) is a tuple , where:

is a finite set of states;

is the initial state;

is the target state;

is a finite set of stochastic edges;

for each , the function assigns a rational weight to each transition of the complete graph with state space .
A (finite, infinite) path in from is a (finite, infinite) sequence of states such that and for every , there is such that and . Finite paths are equivalently called histories. We write (resp. ) for the set of paths (resp. infinite paths), in from state . Given a history and , the accumulated weight of after steps is defined as . This notion extends straightforwardly to infinite paths.
A (randomized) strategy in is a function assigning to every history a distribution over . A strategy is said to be pure whenever the distributions it prescribes are Dirac. A path is an outcome of whenever for every strict prefix , there exists such that and . Basically, the outcomes of a strategy are the paths that are activated by the strategy. We write (resp. ) for the set of finite (resp. infinite) outcomes of from state .
Given a strategy and a state , we denote with
the probability distribution, according to
, over the infinite paths in , defined in the standard way using cylinders based on finite paths from . If is a measurable functions from to , we denote by the expected value of w.r.t. the probability distribution , that is, . In all notations, we may omit to mention the superscript when it is clear in the context, and may omit to mention the starting state when it is , so that corresponds to .Consider the 2wMDP of Figure 1. It has four states , , and , and five edges, labelled with their names (here , , , and ). Weights label pairs of states (but are represented here only for pairs of states that may be activated). Edges , , and have Dirac distributions, while edge has a stochastic choice (represented by the small black square). For readability we do not write the exact distributions, but in this example, they are assumed to be uniform.
2.2 Payoff functions
We are interested in quantitative reachability properties (also called truncatedsum in the literature), which we formalize as follows. Let . We use standard based notations for properties; for instance, we write (resp. , when is an interval of ) when there is (resp. ) such that , and (resp. , when is an interval of ) when for every (resp. for every ). We will often use expressions (in for defining intervals of .
If and , we define the th payoff function as where is the least index such that . If then . The function is measurable, hence for every in , (simply written as ) and are welldefined. We write whenever .
In the rest of the paper, we assume that is a sink state, and that there is a single loop on whose weights are all equal to . This is w.l.o.g. since we will study payoff functions , which only consider the prefix up to the first visit to .
Consider again the example of Figure 1. Consider the strategy which selects or uniformly at random in , and always selects in . Then,
3 The problem
The problem that we tackle in this paper arises from a recent study of an EVcharging problem [14]. The general problem we will define is a relaxed version of the original problem, combining several stochastic constraints (a percentile query over some payoff function and a constraint on the expectation of some payoff function) together with a worstcase obligation. While various payoff functions could be relevant, we focus on those payoff functions that were used for the EVcharging problem, that is, quantitative reachability (i.e., the truncatedsum payoff). We will see that the developed techniques are really specific to our choice of payoff functions.
In this paper, we focus on a combination of sure reachability of the goal state, of a percentile constraint on the proportion of paths having high value for the first payoff, and of a constraint on the expected value of the second payoff.
Let be a 2wMDP. Let . For every , we define the problem as follows: there exists a strategy such that

for all , it holds ;

;

.
We aim at computing the values of for which has a solution. For the rest of this section, we assume that there is a strategy such that . Otherwise trivially has no solutions, for any . This can be decided using the algorithm recently developed in [2].
To illustrate the problem, we consider again the example given in Figure 1. Consider , and . The only way to satisfy the threshold constraint on is that at least half of the paths use , impacting over the expectation of . The other paths have to go to , and then take for some time (provided the play goes back to ) in order to decrease the expectation of , before it becomes possible to take and then (so that the strategy is surely winning). This strategy uses both randomization (at ) and memory (counting the number of times is taken before can be taken).
We call the cartography of our problem the function which associates to every , either true if has a solution, or false otherwise. It is easily seen that the cartography is a threshold function, and can be characterized by an interval (which may be leftopen or leftclosed): In what follows, we describe an algorithmic technique to approximate this interval, and under additional conditions, to compute the bound . Whether the bound belongs to the interval remains open in general.
Link with the electricvehicle (EV) charging problem.
The (centralized) EVcharging problem consists in scheduling power loads within a time interval ( being a fixed time bound) with uncertain exogenous loads, so as to minimize the impact of loading on the electric distribution network (measured through the ageing of the transformer, which depends on the temperature of its winding). Following standard models, time is discretized, and the instantaneous energy consumption at time can be written as the sum of the nonflexible load (consumption outside EV) and the flexible load
, corresponding to the EV charging. The flexible loads at each time are controllable actions, while the nonflexible part is known, or statistically estimated using past databases.
A first constraint on the transformer is given by its capacity: (where is a constant) for every . A second constraint represents the charge required for charging all vehicles on schedule: , where is a constant. The flexible load can thus be seen as a weight function .
While greedy solutions can be used to solve the above constraints, the ageing of thansformer has not been taken into account so far. Using a standard model for the ageing of a transformer (see [5, 14] for details), it can be expressed as a weight function based on a discrete model in which states aggregate information on the system at the the two last timepoints. Globally, a 2wMDP can be built, such that a controller for the EVcharging problem coincides with a solution to , for some bound for the expected ageing of the transformer.
4 Approximated cartography
We fix a 2wMDP and two thresholds . We introduce two simpler optimization problems related to , from which we derive informations on the good values of for which that problem has a solution. As we explain below, our approach is in general not complete. However, we observe that the true part of the cartography of our problem is an interval of the form ; under some hypotheses, we prove that our approach allows to approximate arbitrarily the bound , but may not be able to decide if the interval is leftopen or leftclosed.
4.1 Optimization problems
Let be an integer. We write for the property (which specifies that the target is reached in no more than steps, with a weight larger than or equal to ), and for the property (which means that the target is reached in no more than steps, with a weight smaller than ). We write for the property (the target is not reached during the first steps). By extension, we write , and for the properties , and . Finally, we may also (abusively) use such formulas to denote the set of paths that satisfy them.
For every and every path of of length at least , it holds that: . Moreover, observe that and . As a consequence, for every and every strategy , .
4.1.1 First optimization problem
We define
and for every , we fix a witnessing strategy for up to (i.e. and ).
Note that, since we assume that there is a strategy such that , the constraint of this optimization problem is nonempty. Note also that if is a strategy such that , then , since for every path , whenever .
It is not hard to see that the sequence is nonincreasing (see Appendix). We let . We then have:
[] For every , has no solution.
Proof.
Fix , and assume towards a contradiction that has a solution.
Fix a winning strategy for . By the first winning constraint, there exists such that any outcome satisfies (thanks to König’s lemma). Furthermore, since , then belongs to the domain of the optimization problem defining . Hence, we have
This is then a contradiction with . Hence, we deduce that for every , has no solution. ∎
[] For every , for every , has a solution.
Proof.
Let be an integer, and . Let be a strategy such that
Let be an attractor (memoryless) strategy on , that is, a strategy which enforces reaching ; write for a positive upperbound on the accumulated weight when playing that strategy (from any state). For , define as: play for the first steps, and if is not reached, then play . We show that we can find large enough such that this strategy is a solution to .
The first condition is satisfied, since either the target state is reached during the first steps (i.e. while playing ), or it will be surely reached by playing . Since and , it is the case that , which is the second condition for being a solution to . Finally, thanks to the law of total expectation, we can write:
Now, since is finite, it is the case that . Hence:

, and

.
Let . One can choose large enough such that
We conclude that:
The strategy therefore witnesses the fact that problem has a solution. ∎
4.1.2 Second optimization problem
We now define
Notice that for any , . For every , we fix a witness strategy for up to (so that and ).
This time, it can be observed that the sequence is nondecreasing. We let . From the results and remarks above, we have for any . From Lemma 4.1.1, we get:
[] For any and any , has no solution.
While the status of is in general unknown, we still have the following properties: []

If has a solution, then the sequence is stationary and ultimately takes value . The converse need not hold in general;

does neither imply that has a solution, nor that has no solution.
4.1.3 Summary
Figure 2 summarizes the previous analysis.
The picture seems rather complete, since only the status of remains uncertain. However, it remains to discuss two things: first, the limits and are a priori unknown, hence the cartography is not effective so far. The idea is then to use the sequences and to approximate the limits. We will therefore discuss cases where the two limits coincide (we then say that the approach is almostcomplete), allowing for a converging scheme and hence an algorithm to almost cover the interval with either red (there are no solutions) or green (there is a solution), that is, to almost compute the full cartography of the problem. Second, we should discuss the effectiveness of the approach.
5 Almostcompleteness of the approach
In this section, we discuss the almostcompleteness of our approach, and describe situations where one can show that , which allows to reduce the unknown part of the cartography to the singleton .
The situations for completeness we describe below are conditions over cycles, either on weight or on weight . When we assume that cycles have positive weights, we mean it for every cycle, except for cycles containing , which we assumed are selfloops with weight .
5.1 When all cycles have a positive weight
In this subsection, we assume that the weight of each cycle of is positive (this is the case for instance when the weight of each edge is , i.e., when counts the number of steps). We let be the number of states of .
There exists a constant such that, for any strategy satisfying , and any , it holds:
Proof.
Assuming otherwise, the impact of all runs that do not belong to would be too large for the constraint on . Indeed, applying the law of total expectation, we can write for every :
Write for the minimal (possibly negative) weight appearing in , and for the minimal (positive by hypothesis) weight of cycles in . Noticing that, along any path, at most edges may be outside any cycle, we get
and
We get:
Since the lefthand side is strictly smaller than , we get
∎
For any constant satisfying Lemma 5.1, and any , we have
Proof.
We already remarked that . Now, from Lemma 5.1, for every strategy such that , it holds for any that
Hence, for any strategy and any ,
Taking the infimum over , first in the lefthand side, and then in the righthand side, we get the expected bound. ∎
.
Notice that the result does not hold without the assumption. Indeed, consider the 2wMDP defined by the two deterministic edges and , with . Then, for every , , while .
5.2 When all cycles have a positive weight
We assume that each cycle of has a positive weight. We first notice that: There exists an integer such that for every path from of length not visiting the goal state, it holds . In particular, if satisfies , then .
Using this remark, we can prove:
Proof.
We fix the index as in Lemma 5.2. For any and any path of length larger than , we have
From the first equivalence, we infer that for every , .
Let , and write:
We claim that: []
From this lemma, we get that:
Comments
There are no comments yet.