## Intent

It specifies that a robot should avoid visiting a location a number of times that is different from “n”, i.e., the robot should visit a location exactly “n” times

## LTL Template

Note that the pattern is general and consider the case in which a robot can be in two locations at the same time. For example, a robot can be in an area of a building indicated as l1 (e.g., area 01) and at the same time in a room of the area indicated as l2 (e.g., room 002) at the same time. If the topological intersection of the considered locations is empty, then the robot cannot be in two locations at the same time and the transitions labeled with both l1 and l2 cannot be fired.

## Examples and Known Uses

A robot must enter location $l_1$ exactly $3$ times. The trace $l_4 \rightarrow l_3 \rightarrow l_2 \rightarrow l_2 \rightarrow l_4 \rightarrow ( l_3)^\omega$ violates the mission requirement. The trace $l_1 \rightarrow l_4 \rightarrow l_3 \rightarrow l_1 \rightarrow l_4 \rightarrow l_1 \rightarrow ( l_3)^\omega$ satisfies the mission requirement since location $l_1$ is entered exactly $3$ times.

## Relationships

The LTL formula used to encode Exact Restricted Avoidance is opdained by combining the Lower and the Upper Restricted Avoidance patterns. The Exact Restriceted Avoidance pattern is a variation of the Bounded Existence pattern proposed by Dwyer.

## Occurences

Considering the work of Chen et al., exact restricted avoidance is a natural concept that can be obtained by combining the formulae that specify that a service occurs at least and at maximum a number of times.

## Büchi Automaton representing accepting sequences of events

where circled states are accepting states and states with an incoming arrow with no source are initial states. The automaton above is deterministic.