\section{Learning Concrete Automata}

We briefly survey Angluin's $L^*$ algorithm \cite{Angluin87} for learning regular sets from membership queries and counter-examples, with slightly modified definitions to accommodate for its symbolic extension. Let $\Sigma$ be a finite alphabet and let $\Sigma^*$ be the set of sequences (words) over $\Sigma$. Any order relation $<$ over $\Sigma$ can be naturally lifted to a lexicographic order over $\Sigma^*$. \comment{ that we denote by $<_l$.} With a language $L\subseteq \Sigma^*$ we associate a \emph{characteristic function} $f:\Sigma^*\to\{+,-\}$, where $f(w) = +$ if the word $w \in \Sigma^{*}$ belongs to $L$ and $f(w) = -$, otherwise.

A \emph{deterministic finite automaton}  over $\Sigma$ is a tuple $\mathcal{A} = (\Sigma, Q, \delta,
q_0,F)$, where $Q$ is a non-empty finite set of \emph{states}, $q_0 \in Q$ is
the \emph{initial} state, $\delta : Q \times \Sigma \to Q$ is the \emph{transition
function}, and $F \subseteq Q$ is the set of \emph{final} or \emph{accepting} states.
The transition function $\delta$ can be extended to $\delta: Q \times \Sigma^{*} \to Q$,
where $\delta(q,\epsilon) = q$, and $\delta(q,u \cdot a) = \delta(\delta(q,u),a)$ for $q \in Q$, $a
\in \Sigma$ and $u \in \Sigma^{*}$. A word $w\in \Sigma^{*}$ is \emph{accepted} by $\mathcal{A}$ if
$\delta(q_0,w) \in F$, otherwise $w$ is \emph{rejected}. The language recognized by
$\mathcal{A}$ is the set of all accepted words and is denoted by $L(\mathcal{A})$.

Learning algorithms, represented by the \emph{learner}, are designed to infer
an unknown regular language $L$ (the \emph{target language}). The learner aims
to construct a finite automaton that recognizes $L$ by gathering
information from the \emph{teacher}. The \emph{teacher} knows $L$ and can
provide information about it. It can answer two types of queries:
\emph{membership queries}, i.e., whether a given word belongs to the target
language, and \emph{equivalence queries}, i.e., whether a conjectured automaton
suggested by the learner is the right one. If this automaton fails to accept $L$
the teacher responds to the equivalence query by a \emph{counter-example}, a
word miss-classified by the conjectured automaton.

In the $L^*$ algorithm, the learner starts by asking membership queries. All information provided is suitably gathered in a table structure, the \emph{observation table}. Then, when the information is sufficient, the learner constructs a \emph{hypothesis automaton} and poses an equivalence query to the teacher. If the answer is positive then the algorithm terminates and returns the conjectured automaton. Otherwise the learner accommodates the information provided by the counter-example into the table, asks additional membership queries until it can suggest a new hypothesis and so on, until termination.

A prefix-closed set $ S \uplus R \subset \Sigma^{*} $ is a \emph{balanced $\Sigma$-tree} if $\forall a \in \Sigma$: 1) For every $s \in S$ $s\cdot a \in S\cup R$, and 2)  For every $r\in R$,  $r \cdot a \not \in S\cup R $. Elements of $R$ are called \emph{boundary elements} or \emph{leaves}.
\footnote{We use $\uplus$ for disjoint union.}

\begin{defi} [Observation Table]
An \emph{observation table} is a tuple $T = ( \Sigma, S, R, E, f )$ such that $\Sigma$
is an alphabet, $S \cup R$ is a balanced $\Sigma$-tree, $E$ is a subset of
$\Sigma^{*}$ and $f : (S \cup  R) \cdot E \to \{-, +\}$ is the classification
function, a restriction of the characteristic function of the target language
$L$.
\end{defi}

\noindent The set $(S \cup  R) \cdot E$ is the \emph{sample} associated with the
table, that is, the set of words whose membership is known. The elements of $S$
admit a tree structure isomorphic to a \emph{spanning tree} of the transition
graph rooted in the initial state. Each $s\in S$ corresponds to a state $q$ of
the automaton for which $s$ is an \emph{access sequence}, one of the shortest
words that lead from the initial state to  $q$. The elements of $R$ should tell
us about the back- and cross-edges in the automaton and the elements of $E$ are
``experiments" that should be sufficient to distinguish between states. This
works by associating with every  $s \in S \cup R$ a specialized classification
function $ f_s : E \to \{ - , + \} $, defined as $ f_s (e) = f( s \cdot e)$,
which characterizes the row of the observation table labeled by $s$. To build an
automaton from a table it should satisfy certain conditions.

\begin{defi}[Closed, Reduced and Consistent Tables]
An observation table $T$ is:
    \begin{itemize}
        \item Closed if for every $r \in R$, there exists an $s \in S$, such that $f_r = f_s$;
        \item Reduced if for every $s,s'\in S~f_s\not=f_{s'}$;
        \item Consistent if for every $s, s' \in S$,  $f_{s} = f_{s'}$ implies
        $ f_{s\cdot a }  = f_{ s'\cdot a }, \forall a \in \Sigma$.
    \end{itemize}
\end{defi}
\noindent Note that a reduced table is trivially consistent and that for a closed and
reduced table we can define a function $g:R\to S$ mapping every $r\in R$ to the
unique $s\in S$ such that $f_s=f_r$. From such an observation table $T= ( \Sigma, S,
R, E, f )$ one can construct an automaton $\mathcal{A}_T = (\Sigma, Q, q_0, \delta, F)$ where $Q
=S$, $q_0=\epsilon$, $F=\{s \in S:f_s(\epsilon) = +\}$ and $$ \delta(s,a) = \left\{
\begin{array}{l l} s \cdot a   &  \mbox{ when } s \cdot a \in S\\    g(s\cdot a)
  & \mbox{ when } s \cdot a  \in R \end{array} \right.$$

\noindent The learner attempts to keep the table closed at all times.
The table is not closed when there is some $r \in R $ such that $ f_{r}$ is different from $f_{s}$ for all $s \in S $. To close the table, the learner moves $r$ from $R$ to $S$ and adds the $\Sigma$-successors of $r$, i.e., all words $r\cdot a$ for $a\in\Sigma$, to $R$. The extended table is then filled up by asking membership queries until it becomes closed.

Variants of the $L^*$ algorithm differ in the way they treat counter-examples, as described in more detail in \cite{BergR04}. The original algorithm \cite{Angluin87} adds all the \emph{prefixes} of the counter-example to $S$ and thus possibly creating inconsistency that should be fixed. The version proposed in \cite{maler1995learnability} for learning $\omega$-regular languages adds all the \emph{suffixes} of the counter-example to $E$. The advantage of this approach is that the table always remains consistent and reduced with $S$ corresponding exactly to the set of states. A disadvantage is the possible introduction of redundant columns that do not contribute to further discrimination between states. The symbolic algorithm that we develop in this paper is based on an intermediate variant, referred to in \cite{BergR04} as the \emph{reduced observation algorithm}, where some prefixes of the counter-example are added to $S$ and some suffixes are added to $E$.

\input{AngluinsLearningexample}

\section{Discussion}

We have defined a generic algorithmic scheme for automaton learning, targeting  languages over large alphabets that can be recognized by finite symbolic automata having a modest number of states and transitions. Some ideas similar to ours have been proposed for the particular case of parametric languages  \cite{BergJR06} and recently in a more general setting \cite{alph-refinement,local-alph,bb13sigma} including partial evidential support and alphabet refinement during the learning process.

The genericity of our algorithm is due to a semantic approach (alphabet partitions) but of course, each and every domain will have its own semantic and syntactic specialization in terms of the size and shape of the alphabet partitions. In this work we have implemented an instantiation of this scheme for alphabets such as $(\mathbb{N}, \leq)$ and $(\mathbb{R},\leq)$.
When dealing with numbers, the partition into a finite number of intervals (and monotone sets in higher dimensions) is very natural and used in many application domains ranging from quantization of sensor readings to income tax regulations. It will be interesting to compare the expressive power and succinctness of symbolic automata with other approaches for representing numerical time series and to compare our algorithm with other inductive inference techniques for sequences of numbers.

As a first excursion into the domain, we have made quite strong assumptions on the nature of the equivalence oracle, which, already for small alphabets, is a bit too strong and pedagogical to be realistic. We assumed that it provides the shortest counter-example and also that it chooses always the minimal available concrete symbol. We can relax the latter (or both) and even omit this oracle altogether and replace it by random sampling, as already proposed in \cite{Angluin87} for concrete learning.
Over large alphabets, it might be even more appropriate to employ probabilistic convergence criteria a-la \emph{PAC learning} \cite{valiant1984theory} and be content with a correct classification of a large fraction of the words, thus tolerating imprecise tracing of boundaries in the alphabet partitions.
This topic is subject to ongoing work. Another challenging research direction is the adaptation of our framework to languages over Boolean vectors.

\section*{Introduction}\label{S:Intro}

The main contribution of this paper is a generic algorithm for learning regular languages defined over a large alphabet $\Sigma$. Such an alphabet can be infinite, like $\mathbb{N}$ or $\mathbb{R}$ or just so large, like $\mathbb{B}^n$ for very large $n$ or large subsets of $\mathbb{N}$, so that it is impossible or impractical to treat it in an enumerative way, that is, to write down the entries of the transition function $\delta(q,a)$ for every $a\in \Sigma$. The obvious solution is to use a \emph{symbolic} representation where transitions are labeled by predicates which are applicable to the alphabet in question. Learning algorithms infer an automaton from a finite set of words (the \emph{sample}) for which membership is known. Over small alphabets, the sample should include the set $S$ of all the shortest words that lead to each state (access sequences) and, in addition, the set $S\cdot \Sigma$ of all their $\Sigma$-continuations. Over large alphabets this is not a practical option and as an alternative we develop a symbolic learning algorithm over \emph{symbolic words} which are only partially backed up by the sample. In a sense, our algorithm is a combination of automaton learning and learning of non-temporal predicates. Before getting technical, let us discuss briefly some motivation.

Finite automata are among the corner stones of Computer Science. From a practical point of view they are used routinely in various domains ranging from syntactic analysis, design of user interfaces or administrative procedures to implementation of digital hardware and verification of software and hardware protocols. Regular languages admit a very nice, clean and comprehensive theory where different formalisms such as automata, logic, regular expressions, semigroups and grammars are shown to be equivalent. The problem of learning automata from examples was introduced already in 1956 by Moore \cite{moore1956gedanken}. This problem, like the problem of  automaton minimization,  is closely related to the Nerode right-congruence relation over words associated with every language or sequential function \cite{Nerode58}. This relation declares two \emph{input histories} as equivalent if they lead to the same \emph{future continuations}, thus providing  a crisp characterization of what a \emph{state} in a dynamical system is in terms of observable input-output behavior. All algorithms for learning automata from examples, starting with the seminal work of Gold \cite{Gold72} and culminating in the well-
known $L^*$ algorithm of Angluin \cite{Angluin87} are based on this concept \cite{dehiguera2010book}.

One weakness, however, of the classical theory of regular languages is that it is rather ``thin" and ``flat". In other words, the alphabet is often considered as a small set devoid of any additional structure. On such alphabets, classical automata are good for expressing and exploring the temporal (sequential, monoidal) dimension embodied by the concatenation operations, but  less good in expressing ``horizontal" relationships. To make this statement  more concrete, consider the verification of a system consisting of  $n$ automata running in parallel, making independent as well as synchronized transitions. To express the set of joint behaviors of this product of automata as a formal language, classical theory will force you to use the exponential alphabet of global states and indeed, a large part of verification is concerned with fighting this explosion using constructs such as BDDs and other logical forms that exploit the sparse interaction among components. This is done, however, without a real interaction with classical formal language theory (one exception is the theory of \emph{traces} \cite{Traces} which attempts to treat this issue but in a very restricted context).

These and other considerations led us to use \emph{symbolic automata} as a generic framework for recognizing languages over large alphabets where transitions outgoing from a state are labeled, semantically speaking, by \emph{subsets} of the alphabet.  These subsets are expressed syntactically according to the specific alphabet used:  Boolean formulae when $\Sigma=\mathbb{B}^n$ or by some classes of inequalities when $\Sigma\subseteq\mathbb{N}$ or $\Sigma\subseteq \mathbb{R}$. Determinism and completeness of the transition relation, which are crucial for learning and minimization, can be enforced by requiring that the subsets of $\Sigma$ that label the transitions outgoing from a given state form a \emph{partition} of the alphabet. Such symbolic automata have been used in the past for Boolean vectors \cite{mona95} and have been studied extensively in recent years as acceptors and  transducers where transitions are guarded by predicates of various theories  \cite{Veanes-vmcai11,Veanes-symb}.

Readers working on program verification or hybrid automata are, of course, aware of automata with symbolic transition guards but it should be noted that in the model that we use, \emph{no auxiliary variables} are added to the automaton. Let us stress this point by looking at a popular extension of automata to infinite alphabets, initiated in  \cite{KaminskiF94} using \emph{register automata} to accept \emph{data languages} (see \cite{benedikt2010} for a good exposition of theoretical properties and \cite{HowarSJC12} for learning algorithms). In that framework, the automaton is augmented with additional registers that can store some input letters. The registers can then be compared with newly-read letters and influence transitions.  With register automata one can express, for example, the requirement that the password at login is the same as the password at sign-up. This very restricted use of memory makes register automata much simpler than more notorious automata with variables whose emptiness problem is typically undecidable. The downside is that beyond \emph{equality} they do not really exploit the potential richness of the alphabets and their corresponding theories.

Our approach is different:  we do allow the \emph{values} of the input symbols to influence transitions via predicates, possibly of a restricted complexity. These predicates involve domain \emph{constants} and they partition the alphabet into finitely many classes. For example, over the integers a state may have transitions labeled by conditions of the form $c_1\leq x \leq c_2$  which give real (but of limited resolution) access to the input domain. On the other hand, we insist on a finite (and small) memory so that the exact value of $x$ \emph{cannot} be registered and has no future influence beyond the transition it has triggered.  Many control systems, artificial (sequential machines working on quantized numerical inputs) as well as natural (central nervous system, the cell),  are believed to operate in this manner. The automata that we use, like the  symbolic automata and transducers studied in \cite{Veanes-vmcai11,Veanes-symb,Veanes-SAtoolkit}, are geared toward languages recognized by automata having a large alphabet and a relatively-small state space.

We then develop a symbolic version of Angluin's $L^*$ algorithm for learning regular sets from queries and counter-examples whose output is a symbolic automaton. The main difference relative to the concrete algorithm is that in the latter, every transition $\delta(q,a)$  in a conjectured automaton has at least one word in the sample that exercises it. In the symbolic case, a transition $\delta(q,\sy{a})$ where $\sy{a}$ stands for a \emph{set} of concrete symbols, will be backed up in the sample only by a \emph{subset} of $\sy{a}$. Thus, unlike concrete algorithms where a counter-example always leads to a discovery of one or more new states, in our algorithm it may sometimes only modify the boundaries between partition blocks without creating new states. There are some similarities between our work and another recent adaptation of the $L^*$ algorithm to symbolic automata, the $\Sigma^*$ algorithm of \cite{bb13sigma}. This work is incomparable to ours as they use a richer model of transducers and more general predicates on inputs and outputs. Consequently their termination result is weaker and is relative to the termination of the counter-example guided abstraction refinement procedure.

The rest of the paper is organized as follows. In Section~\ref{S:GeneralLearning} we provide a quick summary of learning algorithms over small alphabets. In Section~\ref{S:SymbolicAutomata} we define symbolic automata and then extend the structure which underlies all automaton learning algorithms, namely the \emph{observation table}, to be symbolic, where symbolic letters represent sets, and where entries in the table are supported only by partial evidence. In Section~\ref{S:SymboliLearningTotalOrder} we write down a symbolic learning algorithm, an adaptation of $L^*$ for totally ordered alphabets such as $\mathbb{R}$ or $\mathbb{N}$ and illustrate the behavior of a prototype implementation. The algorithm is then extended to languages over partially ordered alphabets such as $\mathbb{N}^d$ and $\mathbb{R}^d$ where in each state, the labels of outgoing transition from a monotone partition of the alphabet are represented by finitely many points.  We conclude by a discussion of past and future work.

\section{Learning Regular Sets}\label{S:GeneralLearning}

We briefly survey Angluin's $L^*$ algorithm \cite{Angluin87} for learning regular sets from membership queries and counter-examples, with slightly modified definitions to accommodate for its symbolic extension. Let $\Sigma$ be a finite alphabet and let $\Sigma^*$ be the set of sequences (words) over $\Sigma$. Any order relation $<$ over $\Sigma$ can be naturally lifted to a lexicographic order over $\Sigma^*$. \comment{ that we denote by $<_l$.} With a language $L\subseteq \Sigma^*$ we associate a \emph{characteristic function} $f:\Sigma^*\to\{+,-\}$, where $f(w) = +$ if the word $w \in \Sigma^{*}$ belongs to $L$ and $f(w) = -$, otherwise.

A \emph{deterministic finite automaton}  over $\Sigma$ is a tuple $\mathcal{A} = (\Sigma, Q, \delta,
q_0,F)$, where $Q$ is a non-empty finite set of \emph{states}, $q_0 \in Q$ is
the \emph{initial} state, $\delta : Q \times \Sigma \to Q$ is the \emph{transition
function}, and $F \subseteq Q$ is the set of \emph{final} or \emph{accepting} states.
The transition function $\delta$ can be extended to $\delta: Q \times \Sigma^{*} \to Q$,
where $\delta(q,\epsilon) = q$, and $\delta(q,u \cdot a) = \delta(\delta(q,u),a)$ for $q \in Q$, $a
\in \Sigma$ and $u \in \Sigma^{*}$. A word $w\in \Sigma^{*}$ is \emph{accepted} by $\mathcal{A}$ if
$\delta(q_0,w) \in F$, otherwise $w$ is \emph{rejected}. The language recognized by
$\mathcal{A}$ is the set of all accepted words and is denoted by $L(\mathcal{A})$.

Learning algorithms, represented by the \emph{learner}, are designed to infer
an unknown regular language $L$ (the \emph{target language}). The learner aims
to construct a finite automaton that recognizes $L$ by gathering
information from the \emph{teacher}. The \emph{teacher} knows $L$ and can
provide information about it. It can answer two types of queries:
\emph{membership queries}, i.e., whether a given word belongs to the target
language, and \emph{equivalence queries}, i.e., whether a conjectured automaton
suggested by the learner is the right one. If this automaton fails to accept $L$
the teacher responds to the equivalence query by a \emph{counter-example}, a
word miss-classified by the conjectured automaton.

In the $L^*$ algorithm, the learner starts by asking membership queries. All information provided is suitably gathered in a table structure, the \emph{observation table}. Then, when the information is sufficient, the learner constructs a \emph{hypothesis automaton} and poses an equivalence query to the teacher. If the answer is positive then the algorithm terminates and returns the conjectured automaton. Otherwise the learner accommodates the information provided by the counter-example into the table, asks additional membership queries until it can suggest a new hypothesis and so on, until termination.

A prefix-closed set $ S \uplus R \subset \Sigma^{*} $ is a \emph{balanced $\Sigma$-tree} if $\forall a \in \Sigma$: 1) For every $s \in S$ $s\cdot a \in S\cup R$, and 2)  For every $r\in R$,  $r \cdot a \not \in S\cup R $. Elements of $R$ are called \emph{boundary elements} or \emph{leaves}.
\footnote{We use $\uplus$ for disjoint union.}

\begin{defi} [Observation Table]
An \emph{observation table} is a tuple $T = ( \Sigma, S, R, E, f )$ such that $\Sigma$
is an alphabet, $S \cup R$ is a balanced $\Sigma$-tree, $E$ is a subset of
$\Sigma^{*}$ and $f : (S \cup  R) \cdot E \to \{-, +\}$ is the classification
function, a restriction of the characteristic function of the target language
$L$.
\end{defi}

\noindent The set $(S \cup  R) \cdot E$ is the \emph{sample} associated with the
table, that is, the set of words whose membership is known. The elements of $S$
admit a tree structure isomorphic to a \emph{spanning tree} of the transition
graph rooted in the initial state. Each $s\in S$ corresponds to a state $q$ of
the automaton for which $s$ is an \emph{access sequence}, one of the shortest
words that lead from the initial state to  $q$. The elements of $R$ should tell
us about the back- and cross-edges in the automaton and the elements of $E$ are
``experiments" that should be sufficient to distinguish between states. This
works by associating with every  $s \in S \cup R$ a specialized classification
function $ f_s : E \to \{ - , + \} $, defined as $ f_s (e) = f( s \cdot e)$,
which characterizes the row of the observation table labeled by $s$. To build an
automaton from a table it should satisfy certain conditions.

\begin{defi}[Closed, Reduced and Consistent Tables]
An observation table $T$ is:
    \begin{itemize}
        \item Closed if for every $r \in R$, there exists an $s \in S$, such that $f_r = f_s$;
        \item Reduced if for every $s,s'\in S~f_s\not=f_{s'}$;
        \item Consistent if for every $s, s' \in S$,  $f_{s} = f_{s'}$ implies
        $ f_{s\cdot a }  = f_{ s'\cdot a }, \forall a \in \Sigma$.
    \end{itemize}
\end{defi}
\noindent Note that a reduced table is trivially consistent and that for a closed and
reduced table we can define a function $g:R\to S$ mapping every $r\in R$ to the
unique $s\in S$ such that $f_s=f_r$. From such an observation table $T= ( \Sigma, S,
R, E, f )$ one can construct an automaton $\mathcal{A}_T = (\Sigma, Q, q_0, \delta, F)$ where $Q
=S$, $q_0=\epsilon$, $F=\{s \in S:f_s(\epsilon) = +\}$ and $$ \delta(s,a) = \left\{
\begin{array}{l l} s \cdot a   &  \mbox{ when } s \cdot a \in S\\    g(s\cdot a)
  & \mbox{ when } s \cdot a  \in R \end{array} \right.$$

\noindent The learner attempts to keep the table closed at all times.
The table is not closed when there is some $r \in R $ such that $ f_{r}$ is different from $f_{s}$ for all $s \in S $. To close the table, the learner moves $r$ from $R$ to $S$ and adds the $\Sigma$-successors of $r$, i.e., all words $r\cdot a$ for $a\in\Sigma$, to $R$. The extended table is then filled up by asking membership queries until it becomes closed.

Variants of the $L^*$ algorithm differ in the way they treat counter-examples, as described in more detail in \cite{BergR04}. The original algorithm \cite{Angluin87} adds all the \emph{prefixes} of the counter-example to $S$ and thus possibly creating inconsistency that should be fixed. The version proposed in \cite{maler1995learnability} for learning $\omega$-regular languages adds all the \emph{suffixes} of the counter-example to $E$. The advantage of this approach is that the table always remains consistent and reduced with $S$ corresponding exactly to the set of states. A disadvantage is the possible introduction of redundant columns that do not contribute to further discrimination between states. The symbolic algorithm that we develop in this paper is based on an intermediate variant, referred to in \cite{BergR04} as the \emph{reduced observation algorithm}, where some prefixes of the counter-example are added to $S$ and some suffixes are added to $E$.

\begin{exa} \label{ex:Lstar}
We illustrate the behavior of the $L^{*}$ algorithm while learning a language
$L$ over $\Sigma = \{1,2,3,4,5\}$. We use the tuple $(w,+)$ to indicate a counter-example $w \in
L$ rejected by the conjectured automaton, and $(w,-)$ for the opposite case.
Initially, the observation table is $T_0 = (\Sigma, S, R, E, f)$ with $S = E =
\{\epsilon\}$ and $R = \Sigma$ and we ask membership queries for all words in $(S
\cup R) \cdot E$ to obtain table $T_0$, shown in Fig.~\ref{fig:Angluintables}.
The table is not closed so we move word $1$ to $S$, add its continuations,
$1\cdot\Sigma$ to $R$ and ask membership queries to obtain table $T_1$ which is
now closed. We construct an hypothesis $\mathcal{A}_1$ (Fig.~\ref{fig:AngluinsHA}) from
this table, and pose an equivalence query for which the teacher returns
counter-example $(3\cdot1,-)$. We add $3\cdot1$ and its prefix $3$ to set $S$ and
add all their continuations to the boundary of the table resulting table
$T_2$ of Fig.~\ref{fig:Angluintables}. This table is not consistent:
two elements $\epsilon$ and $3$ in $S$ are equivalent but their successors
$1$ and $3\cdot1$ are not. In order to distinguish the two strings we add to $E$
the suffix $1$ and end up with a closed and consistent table $T_3$. The new
hypothesis for this table is $\mathcal{A}_3$, shown in Fig.~\ref{fig:AngluinsHA}. Once
more the equivalence query will return a counter-example, $(1\cdot3\cdot3,-)$. We
again add the counter-example and prefixes to the table,  ask membership queries
to fill in the table and solve the inconsistency that appears for $1$ and
$1\cdot3$ by adding suffix 3 to the table. The table corresponds now to the
correct hypothesis $\mathcal{A}_5$, and the algorithm
terminates. \qed
\end{exa}

\begin{figure}
    \centering
    \scalebox{.8}{\input{./Figures/Ex_Lstar/ex_Lstar_tables_red.tex}}
    \smallskip
    \caption{Observation tables for Example~\ref{ex:Lstar}.}
    \label{fig:Angluintables}
\end{figure}

\begin{figure}
    \centering
    \scalebox{.9}{
    \begin{tabular}{|@{ \extracolsep{\fill} } c | c | c @{ }|}
        \hline
        $\mathcal{A}_1$ & $\mathcal{A}_3$ & $\mathcal{A}_5$\\

	\begin{tabular}{c}
        \input{./Figures/Ex_Lstar/ex_Lstar_h0}
	\end{tabular}
	    &
	\begin{tabular}{c}
	\input{./Figures/Ex_Lstar/ex_Lstar_h1}
	\end{tabular}
	    &
	\begin{tabular}{c}
	\input{./Figures/Ex_Lstar/ex_Lstar_h2}
	\end{tabular}\\
        \hline\noalign{\smallskip}
    \end{tabular}}
    \caption{Hypotheses for Example~\ref{ex:Lstar}}
    \label{fig:AngluinsHA}
\end{figure}

\section{Symbolic Automata}\label{S:SymbolicAutomata}

In this section we introduce the variant of \emph{symbolic automata} that we use. Symbolic automata \cite{Veanes-vmcai11,Veanes-SAtoolkit} give a more
succinct representation for languages over large finite alphabets and can also
represent languages over infinite alphabets such as $\mathbb{N}$, $\mathbb{R}$, or
$\mathbb{R}^{n}$.
The size of a standard automaton for a language grows linearly with the size of the
alphabet and so does the complexity of learning algorithms such as $L^{*}$.
As we shall see, symbolic automata admit a variant of the $L^{*}$ algorithm
whose complexity is independent of the alphabet size.

Let $\Sigma$ be a large, possibly infinite, alphabet, to which we will refer from now on as the
\emph{concrete} alphabet. We define a symbolic automaton to be an
automaton over $\Sigma$ where each state has a small number of outgoing
transitions labeled by symbols that represent subsets of $\Sigma$. For every state, these subsets form a (possibly different) \emph{partition} of $\Sigma$ and hence the automaton is complete and deterministic. We start with an arbitrary alphabet viewed as an unstructured set and
present the concept in purely semantic manner before we move to ordered sets
and inequalities in subsequent sections.

Let $\sy{\Sigma}$ be a finite alphabet, that we call the \emph{symbolic alphabet} and its elements \emph{symbolic letters} or \emph{symbols}.
Let $\psi:\Sigma \to \sy{\Sigma}$ map concrete letters into symbolic ones. The $\Sigma$-semantics of a \emph{symbolic letter} $\sy{a}\in \sy{\Sigma}$ is defined as
$[\sy{a}]_\psi=\{a \in \Sigma: \psi(a)=\sy{a}\}$ and the set $\{[\sy{a}]_\psi: \sy{a} \in \sy{\Sigma}\}$ forms a \emph{partition} of $\Sigma$. We will often omit $\psi$ from the notation and use $[\sy{a}]$ when $\psi$, which is always present, is clear from the context. The $\Sigma$-semantics can be extended to symbolic words of the form $\sy{w} =
\sy{a}_1 \cdot \sy{a}_2 \cdots \sy{a}_k\in \sy{\Sigma}^*$ as the concatenation of the concrete one-letter languages associated with the respective symbolic letters or, recursively speaking, $[\sy{\epsilon}]=\{\epsilon\}$ and $[\sy{w}\cdot \sy{a}]=[\sy{w}]\cdot [\sy{a}]$ for $\sy{w}\in \sy{\Sigma}^*$, $\sy{a}\in\sy{\Sigma}$.

\begin{defi}[Symbolic Automaton]
    \label{def:symb-aut}
    A \emph{deterministic symbolic automaton}  is a tuple
    $\sy{\mathcal{A}} = (\Sigma,\sy{\Sigma},\psi, Q, \delta, \sy{\delta}, q_0, F)$, where
     \begin{itemize}
         \item $\Sigma$ is the input alphabet,
         \item $\sy{\Sigma}$ is a finite alphabet, decomposable into
                $\sy{\Sigma}=\biguplus _{q\in Q}\sy{\Sigma}_q$,
         \item $\psi=\{\psi_q:q\in Q\}$ is a family of surjective functions
                $\psi_q: \Sigma \to \sy{\Sigma}_q$,
         \item $Q$ is a finite set of states,
         \item $\delta : Q \times \Sigma \to Q$ and $\sy{\delta}:Q \times \sy{\Sigma} \to Q$
		are the concrete and symbolic transition functions respectively,
		such that $\delta(q,a) = \sy{\delta}(q,\psi_q(a))$,
         \item $q_0$ is the initial state and $F$ is a set of accepting states.
    \end{itemize}
\end{defi}

\noindent The transition function is extended to words as in the concrete case and the
symbolic automaton can be viewed as an acceptor of a concrete language. When at
$q$ and reading a concrete letter $a$, the automaton will take the transition
$\sy{\delta}(q,\sy{a})$ where $\sy{a}$ is the \emph{unique} element of $\sy{\Sigma}_q$
satisfying $a\in [\sy{a}]$. Hence $L(\sy{\mathcal{A}})$ consists of all concrete words
whose run leads from $q_0$ to a state in $F$. A language $L$ over alphabet $\Sigma$
is symbolic recognizable if there exists a symbolic automaton $\sy{\mathcal{A}}$ such
that $L = L(\sy{\mathcal{A}})$.

\noindent {\bf Remark}: The association of a \emph{symbolic language} with a symbolic automaton is more subtle because we allow different partitions of $\Sigma$ and hence different symbolic input alphabets at different states. The transition to be taken while being in a state $q$ and reading a symbol $\sy{a}\not \in \sy{\Sigma}_q$ is well defined only when $[\sy{a}]\subseteq [\sy{a'}]$ for some $\sy{a'}\in \sy{\Sigma}_q$.  Such a model can be transformed into an automaton which is complete over a  symbolic alphabet which is common to all states as follows.  Let $$\sy{\Sigma}'=\prod_{q\in Q} \sy{\Sigma}_q, \mbox{~with the $\Sigma$-semantics~~}  [(\sy{a}_1,\ldots,\sy{a}_n)]=[\sy{a_1}]\cap \ldots \cap [\sy{a}_n],$$ and let $\tilde{\sy{\Sigma}}=\{\sy{b}\in \sy{\Sigma}':[\sy{b}]\not = \emptyset\}$. Then we define $\sy{\widetilde{\mathcal{A}}}=(\tilde{\sy{\Sigma}}, Q, \tilde{\delta}, q_0, F)$ where, by construction, for every $\sy{b}\in \tilde{\sy{\Sigma}}$ and every $q\in Q$, there is a unique $\sy{a}\in \sy{\Sigma}_q$ such that $[\sy{b}]\subseteq [\sy{a}]$ and hence one can define
the transition function as $\tilde{\sy{\delta}}(q,\sy{b})=\sy{\delta}(q,\sy{a})$. This model is more comfortable for language-theoretic studies but in the learning context it introduces an unnecessary blow-up in the alphabet size and the number of queries for every state. For this reason we stick in this
paper to the Definition~\ref{def:symb-aut} which is more economical. A similar approach of state-local abstraction has been taken in \cite{local-alph} for learning parameterized language. The construction of $\sy{\Sigma}'$ is similar to the minterm construction of \cite{Veanes-minimization} used to create a common alphabet in order to apply the minimization algorithm of Hopcroft to symbolic automata. Anyway, in our learning framework symbolic automata are used to read concrete and not symbolic words. \qed

It is straightforward that for a finite concrete alphabet $\Sigma$ the set of languages accepted by symbolic automata coincides with the set of recognizable
regular languages over $\Sigma$. Moreover, even when the alphabet is infinite, closure under Boolean operations is preserved.

\begin{prop}[Closure under Boolean Operations]
  Languages accepted by deterministic symbolic automata are effectively closed
under Boolean operations.
\end{prop}

\proof
Closure under complement is immediate by complementing the set of accepting
states. For intersection the standard product construction is adapted as follows.
Let $L_1,L_2$ be languages recognized by the symbolic automata
$\sy{\mathcal{A}}_1=(\Sigma,\sy{\Sigma}_1,\psi_1,Q_1,\delta_1, \sy{\delta}_1,q_{01},F_1)$, and
$\sy{\mathcal{A}}_2=(\Sigma,\sy{\Sigma}_2,\psi_2,Q_2,\delta_2, \sy{\delta}_2,q_{02},F_2)$, respectively.
Let $\sy{\mathcal{A}}= (\Sigma,\sy{\Sigma},\psi,Q,\delta, \sy{\delta},q_{0},F)$, where
\begin{itemize}
    \item $Q=Q_1\times Q_2$, $q_0=(q_{01},q_{02})$, $F=F_1\times F_2$,
    \item For every $(q_1,q_2)\in Q$
    \begin{itemize}
        \item $\sy{\Sigma}_{(q_1,q_2)} = \{(\sy{a}_1,\sy{a}_2) \in \sy{\Sigma}_1
                \times \sy{\Sigma}_{2} \mid [\sy{a}_1] \cap [\sy{a}_2] \neq \emptyset
\}$
        \item $\psi_{(q_1,q_2)}(a) = (\psi_{1,q_1}(a),\psi_{2,q_2}(a))$,
                $\forall a\in \Sigma$
        \item $\sy{\delta}((q_1,q_2),(\sy{a}_1,\sy{a}_2)) =
                (\sy{\delta}_1(q_1,\sy{a}_1),\sy{\delta}_2(q_2,\sy{a}_2))$,
                $\forall (\sy{a}_1,\sy{a}_2)\in \sy{\Sigma}_{(q_1,q_2)}$
    \end{itemize}
\end{itemize}
It is sufficient to observe that the corresponding implied concrete automata
$\mathcal{A}_1$, $\mathcal{A}_2$ and $\mathcal{A}$ satisfy $\delta((q_1,q_2),a)= (\delta_1(q_1,a),\delta_2(q_2,a))$ and
the standard proof that $L(\mathcal{A})=L(\mathcal{A}_1)\cap L(\mathcal{A}_2)$ follows. Closure under union and set difference is then evident.  \qed
The above product construction is used to implement equivalence queries where both the target language and the current conjecture are represented by symbolic automata. A counter-example is found by looking for a shortest path in the product automaton from the initial state to a state in $F_1\times (Q_2-F_2) \cup (Q_1-F_1)\times F_2$ and selecting a lexicographically minimal concrete word along that path.

\begin{figure}[ht]
\begin{subfigure}[b]{.6\textwidth}
\centering
\scalebox{.85}{ \input{./Figures/Ex_SA/exSA} }
\end{subfigure}
\hfill
\begin{subfigure}[b]{.38\textwidth}
\centering
  \input{./Figures/Ex_SA/exSA_delta}
  \vspace{2.5em}
\end{subfigure}
 \caption{A symbolic automaton $\sy{\mathcal{A}}$ with its symbolic transition function.}
 \label{Fig:ExampleSymbolicAutomaton}
\end{figure}

\begin{exa}\label{ex:1dim}
Figure~\ref{Fig:ExampleSymbolicAutomaton} shows a symbolic automaton equivalent
to automaton $\mathcal{A}_5$ of Figure~\ref{fig:AngluinsHA}.
The symbolic alphabets for the states are
$\sy{\Sigma}_{q_0} = \{\sy{a}_0, \sy{a}_1\}$,
$\sy{\Sigma}_{q_1} = \{\sy{a}_2, \sy{a}_3\}$,
$\sy{\Sigma}_{q_2} = \{\sy{a}_4, \sy{a}_5, \sy{a}_6, \sy{a}_7\}$,
$\sy{\Sigma}_{q_3} = \{\sy{a}_8\}$,
and the $\Sigma$-semantics for the symbols is
$[\sy{a}_0] = \{1,2\}$,
$[\sy{a}_1] = \{3,4,5\}$,
$[\sy{a}_2] = \{3\}$,
$[\sy{a}_3] = \{1,2,4,5\}$, etc..
The same automaton can accept a language over the uncountable alphabet
$\Sigma = [0,100) \subset \mathbb{R}$, defining $\psi$ as shown in Figure~\ref{Fig:ExamplePsiFunction1dim}.
\end{exa}

\begin{figure}[ht]
 \centering
\scalebox{.85}{\input{./Figures/Ex_SA/exSA_psi}}
 \caption{The concrete semantics of the symbols of automaton $\sy{\mathcal{A}}$ of Fig.~\ref{Fig:ExampleSymbolicAutomaton}, when defined over $\Sigma = [0,100) \subseteq \mathbb{R}$.}
 \label{Fig:ExamplePsiFunction1dim}
\end{figure}

\section{Symbolic Observation Tables}\label{S:SymboliLearning}

In this section we adapt observation tables to the symbolic setting. They are
similar to the concrete case with the additional notions  of evidences and
evidence compatibility.

\begin{defi}[Balanced Symbolic $\Sigma$-Tree]
    A \emph{balanced symbolic $\Sigma$-tree} is a  tuple
$(\sy{\Sigma},\sy{S},\sy{R}$, $\psi)$ where
    \begin{itemize}
        \item $\sy{S}\uplus \sy{R}$ is a prefix-closed subset of $\sy{\Sigma}^{*}$
        \item $\sy{\Sigma}=\biguplus_{\sy{s}\in \sy{S}}\sy{\Sigma}_{\sy{s}}$ is a
                symbolic alphabet
        \item $\psi=\{\psi_{\sy{s}}\}_{\sy{s} \in \sy{S}}$
                is a family of total surjective functions of the form
                $\psi_{\sy{s}}:\Sigma\to\sy{\Sigma_s}$.
    \end{itemize}
It is required that for every $\sy{s} \in \sy{S}$ and $\sy{a}\in
\sy{\Sigma}_{\sy{s}}$, $\sy{s}\cdot \sy{a}\in \sy{S}\cup \sy{R}$  and for any
$\sy{r} \in \sy{R}$ and $\sy{a}\in\sy{\Sigma}$, $\sy{r}\cdot \sy{a}\not
\in\sy{S}\cup \sy{R}$ . Elements of $\sy{R}$ are called boundary elements of the
tree.
\end{defi}

\noindent We will use observation tables whose rows are symbolic words and hence an
entry in the table will constitute a statement about the inclusion or exclusion
of a large \emph{set} of concrete words in the language. We will not ask
membership queries concerning all those concrete words, but only for a small
representative subset that we call \emph{evidence}.

\begin{defi}[Symbolic Observation Table]
A \emph{symbolic observation table}  is a tuple
$\sy{T}=(\Sigma, \sy{\Sigma}, \sy{S}, \sy{R}, \psi, E, \sy{f}, \mu)$ such that
    \begin{itemize}
        \item $\Sigma$ is an alphabet,
        \item $(\sy{\Sigma},\sy{S},\sy{R},\psi)$  is a balanced symbolic
                $\Sigma$-tree (with $\sy{R}$ being its \emph{boundary}),
        \item $E$ is a subset of $ \Sigma^{*}$,
        \item  $\sy{f} : ( \sy{S} \cup \sy{R} ) \cdot E \to \{-,+\}$
                is the symbolic classification function
        \item  $\mu : (\sy{S} \cup \sy{R} ) \cdot E \to
                2^{\Sigma^{*}}-\{\emptyset\}$
                is an evidence function satisfying
                $\mu(\sy{w}) \subseteq [\sy{w}]$.
                The image of the evidence function is prefix-closed:
                $w\cdot a \in \mu(\sy{w}\cdot \sy{a}) \Rightarrow w \in
                \mu(\sy{w})$.
    \end{itemize}
\end{defi}

\noindent As for the concrete case we use $ \sy{f}_{\sy{s}} : E \to \{-,+\}$ to
denote the partial evaluation of $\sy{f}$ to some symbolic word $ \sy{s} \in
\sy{S} \cup \sy{R}$, such that, $ \sy{f}_{\sy{s}}(e) = \sy{f}(\sy{s}\cdot  e)$.
Note that the set $E$ consists of \emph{concrete} words but this poses no
problem because elements of $E$ are used only to distinguish between states and
do not participate in the derivation of the symbolic automaton from the table.
Concatenation of a symbolic word and a concrete one follows concatenation of
symbolic words as defined above where each concrete letter $a$ is considered as
a symbolic letter $\sy{a}$ with $[\sy{a}] = \{a\}$ and $\mu(\sy{a}) = a$.
The notions of closed, consistent and reduced table are similar to the concrete
case.

The set $\sy{M}_{\sy{T}} = (\sy{S} \cup \sy{R}) \cdot E$ is called the
\emph{symbolic sample} associated with $\sy{T}$. We require that for each word
$\sy{w}\in \sy{M}_{\sy{T}}$ there is at least one concrete $w\in \mu(\sy{w})$
whose membership in $L$, denoted by $f(w)$, is known. The set of such words is
called the \emph{concrete sample} and is defined as $M_{\sy{T}}=\{s\cdot e: s\in
\mu(\sy{s}), \sy{s}\in \sy{S}\cup\sy{R}, e\in E\}$. A table where  all evidences
of the same symbolic word admit the same classification is called
\emph{evidence-compatible}.

\begin{defi}[Table Conditions]
A table $\sy{T}=(\Sigma, \sy{\Sigma}, \sy{S}, \sy{R}, \psi, E, \sy{f}, \mu)$ is
    \begin{itemize}
        \item Closed if $ \forall \sy{r} \in \sy{R}$,
                $\exists \sy{s}=g(\sy{r}) \in \sy{S}$, $\sy{f}_{\sy{r}} =
                \sy{f}_{\sy{s}}$,
        \item Reduced if $\forall \sy{s}, \sy{s'} \in \sy{S}$, $\sy{f}_{\sy{s}}
                \neq \sy{f}_{\sy{s'}}$,
        \item Consistent if $\forall \sy{s}, \sy{s}' \in \sy{S}$,  $\sy{f_{s} =
                f_{s'}}$ implies
                $ \sy{f_{s\cdot a }  = f_{s'\cdot a }}, \forall \sy{a} \in
                \sy{\Sigma_s}$.
        \item Evidence compatible if $\forall \sy{w} \in \sy{M}_{\sy{T}}$,
                $\forall w_1,w_2 \in \mu (\sy{w}), f( w_1 ) = f( w_2 )$.
    \end{itemize}
\end{defi}
\noindent When a table $\sy{T}$ is evidence compatible the symbolic classification
function $\sy{f}$ can be defined for every $\sy{s} \in ( \sy{S} \cup \sy{R} )$
and $e \in E$ as $\sy{f}(\sy{s} \cdot e) = f(s \cdot e)$, $s \in \mu(\sy{s})$.

\begin{thm}[Automaton from Table]
    \label{th:table-aut}
From a closed, reduced and evidence compatible table one can construct a
deterministic symbolic automaton compatible with the concrete sample.
\end{thm}

\proof
The proof is similar to the concrete case. Let $\sy{T}=(\Sigma, \sy{\Sigma},
\sy{S}, \sy{R}, \psi, E, \sy{f}, \mu)$ be such a table, which is reduced and
closed and thus a function $g : \sy{R} \to \sy{S}$ such that $g(\sy{r}) =
\sy{s}$ if{f} $\sy{f}_{\sy{r}} = \sy{f}_{\sy{s}}$ is well defined.
The automaton derived from the table is then $\sy{\mathcal{A}}_{\sy{T}}=
(\Sigma,\sy{\Sigma},\psi, Q,\sy{\delta}, q_0, F)$ where:
    \begin{itemize}
      \itemsep.5em
        \item $Q = \sy{S}$, $q_0 = \sy{\epsilon}$
        \item $F = \{\sy{s} \in \sy{S} \mid \sy{f}_{\sy{s}}(\epsilon)
                      = +\}$
        \item $\sy{\delta} : Q \times \sy{\Sigma} \to Q$ is defined as
                $ \sy{\delta}(\sy{s},\sy{a}) =
                   \left\{
                     \begin{array}{l l} \sy{s} \cdot \sy{a}
                            &  \mbox{ when } \sy{s} \cdot \sy{a} \in \sy{S}\\
                        g(\sy{s} \cdot \sy{a})
                            &  \mbox{ when } \sy{s} \cdot \sy{a} \in \sy{R}
                     \end{array}
                   \right.$
    \end{itemize}
By construction and like the $L^*$ algorithm,  $\sy{\mathcal{A}}_{\sy{T}}$ classifies
correctly the symbolic sample and, due to evidence compatibility, this holds
also for
the concrete sample. \qed

\section{Learning Languages over Ordered Alphabets}\label{S:SymboliLearningTotalOrder}

In this section we present a symbolic learning algorithm starting with an
intuitive verbal description. The algorithmic scheme is similar to the concrete
$L^{*}$ algorithm but differs in the treatment of counter-examples and the new
concept of evidence compatibility. Whenever the table is not closed, $\sy{S}\cup
\sy{R}$ is extended until closure. Then a conjectured automaton
$\sy{\mathcal{A}}_{\sy{T}}$ is constructed and an equivalence query is posed. If the
answer is positive we are done. Otherwise, the teacher provides a
counter-example leading to the extension of $\sy{S}\cup\sy{R}$ and/or  $E$.
Whenever such an extension occurs, additional membership queries are
posed to fill the table. The table is always kept evidence compatible and
reduced except temporarily during the processing of counter-examples.

From now on we assume $\Sigma$ to be a  \emph{totally ordered} alphabet with a minimal
element $a_0$  and restrict ourselves to symbolic automata where the concrete
semantics for every symbolic letter is an interval. In the case of a dense order like in $\mathbb{R}$, we assume the intervals to be left-closed and right-open. The order on the alphabet can  be extended naturally to a lexicographic order on $\Sigma^{*}$. Our algorithm
also assumes that the teacher provides a counter-example of minimal length which
is  minimal with respect to the lexicographic order. This strong assumption
improves the performance of the algorithm and its relaxation is discussed in
Section~\ref{S:discussion}.

The rows of the observation table consist of symbolic words because we want to
group together all concrete letters and words that are assumed to induce the
same behavior in the automaton. New symbolic letters are introduced in two
occasions: when a new state is discovered or when a partition is modified due to
a counter-example. In both cases we set the concrete semantics $[\sy{a}]$ to the
largest possible subset of $\Sigma$, given the current evidence (in the first case
it will be $\Sigma$). As an evidence we always select the smallest possible $a \in
[\sy{a}]$ ($a_0$ when $[\sy{a}]=\Sigma$).  The choice of the right evidences is a key
point for the performance of the algorithm as we want to  keep the concrete
sample as small as possible and avoid posing unnecessary queries. For infinite
concrete alphabets this choice of evidence guarantees termination.

\input{algorithms/symbolic_alg}
\input{algorithms/procedures}

The initial symbolic table is $\sy{T} = ( \Sigma, \sy{\Sigma}, $ $\sy{S}, \sy{R}, \psi,
E, \sy{f}, \mu)$, where $\sy{\Sigma} = \{\sy{a_0}\}$, $[\sy{a}_0] = \Sigma$, $\sy{S} = \{
\sy{\epsilon} \} $, $\sy{R} = \{\sy{a_0}\}$, $E = \{\epsilon \}$, and
$\mu(\sy{a_0})=\{a_0\}$. The table is filled by membership queries concerning
$\epsilon$ and $a_0$. Whenever $\sy{T}$ is not closed, there is some $\sy{r} \in
\sy{R}$ such that $\sy{f}_{\sy{r}} \neq \sy{f}_{\sy{s}}$ for every $\sy{s} \in \sy{S}$. To
close the table we move  $\sy{r}$ from $\sy{R}$ to $\sy{S}$, recognizing it as a
new state, and checking the behavior of its continuation. To this end we add to
$\sy{R}$ the word $\sy{r'} = \sy{r} \cdot \sy{a}$, where $\sy{a}$ is a new symbolic
letter with $[\sy{a}] = \Sigma$.
We extend the evidence function by letting $\mu(\sy{r'})=\mu(\sy{r}) \cdot a_0$,
assuming that all elements of $\Sigma$ behave as $a_0$ from $\sy{r}$.
Once $\sy{T}$ is closed we construct a hypothesis automaton as described in
the proof of Theorem~\ref{th:table-aut}.

When a counter-example $w$ is presented, it is of course not part of the
concrete sample. A miss-classified word in the conjectured automaton means that
somewhere a wrong transition is taken. Hence  $w$ admits a factorization $w=u
\cdot b \cdot v$ where $u \in \Sigma^{*}$ and $b \in \Sigma$ is where the first wrong
transition is taken. Obviously we do not know $u$ and $b$ in advance but know
that this
happens in the following two cases. Either $b$ leads to an undiscovered state in
the automaton of the target language, or letter $b$ does not belong to the interval
it was assumed to belong in the conjectured automaton. The latter case happens
only when $b$ does not belong to the evidence function. Since counter-example $w$
is minimal, it admits a factorization $w=u \cdot b \cdot v$, where $u$ is the
largest prefix of $w$ such that $u \in \mu(\sy{u})$ for some $\sy{u}\in
\sy{S}\cup \sy{R}$ but $s\cdot b \notin \mu(\sy{u}')$ for any word $\sy{u}'$ in
the symbolic sample. We consider two cases, $\sy{u}\in \sy{S}$ and $\sy{u}\in\sy{R}$.

In the first case, when $\sy{u}\in \sy{S}$, $\sy{u}$ is already a state in the hypothesis
but $b$ indicates that the partition boundariues are not correctly defined and
need refinement. That is, $u\cdot b $ was wrongly considered to be part of $[\sy{u}\cdot \sy{a}]$
for some $\sy{a} \in \sy{\Sigma}_{\sy{u}}$, and thus $b$ was wrongly considered to be
part of $[\sy{a}]$.
Due to minimality, all letters in $[\sy{a}]$ less than letter $b$ behave like $\mu(\sy{a})$.
We assume that  all remaining letters in $[\sy{a}]$ behave like $b$ and
map them to a new symbol $\anew$ that we add to $\sy{\Sigma}_{\sy{u}}$.
We then update $\psi_{\sy{u}}$ such that $\psi'_{\sy{u}}(a) = \anew$ for all $a \in [\sy{a}], a\geq b$, and
$\psi'_{\sy{u}}(a) = \psi_{\sy{u}}(a)$, otherwise. The evidence function is updated by
letting $\mu(\sy{u} \cdot \anew) = \mu(\sy{u}) \cdot b$ and $\sy{u}\cdot\anew$ is added to $\sy{R}$.

In the second case, the symbolic word $\sy{u}$ is part of the boundary.
From the counterexample we deduce that $\sy{u}$ is not equivalent to any of the
existing states in the hypothesis and should form a new state.
Specifically, we find the prefix $\sy{s}$ that was considered to be equivalent
to $\sy{u}$, that is $g(\sy{u})=\sy{s}\in \sy{S}$. Since the table is reduced
$\sy{f}_{\sy{u}}\not=\sy{f}_{\sy{s'}}$ for any other $\sy{s'}\in \sy{S}$.
Because $w$ is the shortest counter-example, the classification of $\sy{s}\cdot
b \cdot v$ in the automaton is correct (otherwise $s\cdot b \cdot v$, for some
$s\in [\sy{s}]$ would constitute a shorter counter-example) and different from
that of $u\cdot b \cdot v$. We conclude that $\sy{u}$ is a new state, which is added to
$\sy{S}$. To distinguish between $\sy{u}$ and $\sy{s}$ we add to $E$ the word
$b \cdot v$, possibly with some of its suffixes (see \cite{BergR04}
for a more detailed discussion of counter-example processing).

As $\sy{u}$ is a new state we need to add its continuations to $R$. We
distinguish two subcases depending on $b$.
If $b = a_0$, the smallest element of $\Sigma$, then a new symbolic letter $\anew$
is added to $\sy{\Sigma}$, with $[\anew] = \Sigma$ and $\mu(\sy{u} \cdot \anew) =
\mu(\sy{u}) \cdot a_0$, and the symbolic word $\sy{u} \cdot \anew$ is added to
$\sy{R}$.
If $b\not = a_0$ then \emph{two} new symbolic letters, $\anew$ and
$\anew'$, are added to $\sy{\Sigma}$ with $[\anew] = \{a : a < b\}$, $[\anew'] =
\{a  : a \geq b\}$, $\mu(\sy{u} \cdot \anew) = \mu(\sy{u}) \cdot a_0$ and
$\mu(\sy{u} \cdot \anew') = \mu(\sy{u}) \cdot b$. The words $\sy{u}\cdot
\anew$ and $\sy{u}\cdot  \anew'$ are added to $\sy{R}$.

A detailed description of the algorithm is given in Algorithm~\ref{alg:symbolic}
and its major procedures, table closing and counter-example treatment are described
in Procedures~\ref{alg:CloseTable} and \ref{alg:TreatCex} respectively.
A statement of the form $\sy{\Sigma}'=\sy{\Sigma}\cup\{\sy{a}\}$ indicates the introduction
of a new symbolic letter $\sy{a}\not\in \sy{\Sigma}$. We use $MQ$ and $EQ$ as shorthands
for membership and equivalence queries, respectively. In the following we illustrate the symbolic algorithm as applied to a
language over an infinite alphabet.

\begin{figure}[ht]
    \input{./Figures/Ex_SL2/SLex2_tables.tex}
    \smallskip
    \caption{Observation tables for Example~\ref{ex:SLex2}.}
    \label{fig:SLex2_tables}
\end{figure}

\begin{figure}[ht]
\resizebox{\textwidth}{!}{\begin{tabular}{| c | c | c |}
\hline
   $\sy{\mathcal{A}}_{1}$ & $\sy{\mathcal{A}}_{2}$ & $\sy{\mathcal{A}}_{3}$ \\
   \scalebox{1}{\input{./Figures/Ex_SL2/SLex2_psi1}} &
   \scalebox{1}{\input{./Figures/Ex_SL2/SLex2_psi2}} &
   \scalebox{1}{\input{./Figures/Ex_SL2/SLex2_psi3}} \\
   \scalebox{1.3}{\input{./Figures/Ex_SL2/SLex2_h1}} &
   \scalebox{1.3}{\input{./Figures/Ex_SL2/SLex2_h2}} &
   \scalebox{1.3}{\input{./Figures/Ex_SL2/SLex2_h3}}  \\
\hline
\end{tabular}}\par
\resizebox{\textwidth}{!}{\begin{tabular}{| c | c |}
   $\sy{\mathcal{A}}_{5}$ & $\sy{\mathcal{A}}_{6}$ \\
   \scalebox{.9}{\input{./Figures/Ex_SL2/SLex2_psi5}} &
   \scalebox{.9}{\input{./Figures/Ex_SL2/SLex2_psi6}} \\
   \scalebox{1.1}{\input{./Figures/Ex_SL2/SLex2_h5}}  &
   \scalebox{1.1}{\input{./Figures/Ex_SL2/SLex2_h6}} \\
\hline
   $\sy{\mathcal{A}}_{7}$ & $\sy{\mathcal{A}}_{8}$ \\
   \scalebox{.9}{\input{./Figures/Ex_SL2/SLex2_psi7}} &
   \scalebox{.9}{\input{./Figures/Ex_SL2/SLex2_psi8}} \\
   \scalebox{1.1}{\input{./Figures/Ex_SL2/SLex2_h7}} &
   \scalebox{1.1}{\input{./Figures/Ex_SL2/SLex2_h8}} \\
\hline
\end{tabular}}
    \caption{Hypotheses and $\Sigma$-semantics for Example~\ref{ex:SLex2}}
    \label{fig:SLex2_hypotheses}
\end{figure}

\begin{exa}\label{ex:SLex2}
Let  $\Sigma  = [0,100) \subset \mathbb{R}$ with the usual order and let  $L \subseteq
\Sigma^{*}$ be a target language. Fig.~\ref{fig:SLex2_tables} shows the evolution of the symbolic observation
tables and Fig.~\ref{fig:SLex2_hypotheses} depicts the corresponding automata and the concrete semantics of the symbolic alphabets.

We initialize the table with $\sy{S}=\{\sy{\epsilon}\}$, $\sy{R}=\{\sy{a}_0\}$,
$\mu(\sy{a}_0)=\{0\}$ and $E=\{\epsilon\}$ and ask membership queries for $\epsilon$ (rejected)
and $0$ (accepted). The obtained table, $\sy{T}_0$ is not closed so we move $\sy{a}_0$ to
$\sy{S}$, introduce $\sy{\Sigma}_{\sy{a}_0} = \{\sy{a}_1\}$, where $\sy{a}_1$ is a new symbol, and add $\sy{a}_0 \cdot \sy{a}_1$ to $R$ with
$\mu(\sy{a}_0 \cdot \sy{a}_1)=0 \cdot 0$. Asking membership queries we obtain the closed table
$\sy{T}_1$ and its automaton $\sy{\mathcal{A}}_1$. We pose an equivalence query and obtain $(50,-)$
as a (minimal) counter-example which implies that all words smaller than $50$
are correctly classified. We add a new symbol $\sy{a}_2$ to $\sy{\Sigma}_{\sy{\epsilon}}$ and
redefine the concrete semantics to $[\sy{a}_0]=\{a<50\}$ and $[\sy{a}_2]=\{a\geq 50\}$. As
evidence we select the smallest possible letter, $\mu(\sy{a}_2)=50$, ask membership queries
to obtain the closed table $\sy{T}_2$ and automaton $\sy{\mathcal{A}}_2$.

For this hypothesis we get a counter-example $(0 \cdot 30,-)$ whose prefix $0$ is
already in the sample, hence the misclassification occurs in the second
transition. We refine the alphabet partition for state $\sy{a}_0$ by introducing a
new symbol $\sy{a}_3$ and letting $[\sy{a}_1]=\{a<30\}$ and $[\sy{a}_3]=\{a\geq 30\}$. Table $\sy{T}_3$
is closed but automaton $\sy{\mathcal{A}}_3$ is still incorrect and a counter-example
$(50\cdot 0,-)$ is provided. The prefix $50$ belongs to the evidence of $\sy{a}_2$
and is moved from the boundary to become a new state and its successor $\sy{a}_2 \cdot
\sy{a}_4$, for a new symbol $\sy{a}_4$, is added to $\sy{R}$. To distinguish $\sy{a}_2$ from
$\sy{\epsilon}$, the suffix $0$ of the counter-example is added to $E$ resulting in
$\sy{T}_4$ which is not closed. The newly discovered state $\sy{a}_0 \cdot \sy{a}_1$ is added to
$\sy{S}$, the filled table $\sy{T}_5$ is closed and the conjectured automaton $\sy{A}_5$
has two additional states.

Subsequent equivalence queries result counter-examples $(50\cdot 20,+)$,
$(50\cdot 80,-)$ and $(50\cdot 50 \cdot 0,+)$ which are used to refine the
alphabet partition at state $\sy{a}_2$ and modify its outgoing transitions
progressively as seen in automata $\sy{\mathcal{A}}_6$, $\sy{\mathcal{A}}_7$ and $\sy{\mathcal{A}}_8$, respectively.
Automaton $\sy{\mathcal{A}}_8$ accepts the target language and the algorithm terminates. \qed
\end{exa}

\noindent Note that for the language in Example~\ref{ex:Lstar},
the symbolic algorithm needs around $30$ queries instead of the $80$ queries
required by $L^*$. If we choose to learn a language as the one
described in Example~\ref{ex:SLex2}, restricting the concrete alphabet to the
finite alphabet $\Sigma = \{1,\dots, 100\}$, then $L^*$ requires around $1000$
queries compared to $17$ queries required by our symbolic algorithm.
As we shall see in Section~\ref{S:complexity}, the complexity of the symbolic
algorithm does not depend on the size of the concrete alphabet, only on the
number of transitions.

\section{Learning Languages over Partially-ordered Alphabets}\label{S:PartialOrderedAlphabets}

In this section we sketch the extension of the results of this paper to
partially-ordered alphabets of the form $\Sigma=X^d$ where $X$ is a totally-ordered
set such as an interval $[0,k)\subseteq\mathbb{R}$.  Letters of $\Sigma$ are $d$-tuples of the form
$\vx = \left(x_1, \dots, x_d\right)$ and the minimal element is $\vzero =
\left(0, \dots, 0\right)$.
The usual partial order on this set is defined as $\vx \leq \vy$ if
and only if $x_i \leq y_i$ for all $i = 1,\dots,d$. When $\vx  \leq \vy$ and
$x_i \neq y_i$ for some $i$ the inequality is strict, denoted by $\vx<\vy$, and
we say then that $\vx$ \emph{dominates} $\vy$. Two elements are
\emph{incomparable}, denoted by $\vx || \vy$, if $x_i<y_i$ and $x_j>y_j$ for
some $i$ and $j$.

For partially-ordered sets, a natural extension of the partition of an
ordered set into intervals is a \emph{monotone} partition, where for each
partition block $P$ there are no three points such that $\vx<\vy<\vz$,
$\vx,\vz\in P$, and $ \vy\not \in P$. We define in the following such
partitions represented by a finite set of points.

A \emph{forward cone} $B^+(\vx) \subset \Sigma$ is the set of all
points dominated by a point $\vx\in\Sigma$ (see Fig.~\ref{Fig:forwardAndBackwardCones}).
Let $F=\{\vx_1,\ldots,\vx_l\}$ be a set of points, then $B^+(F)=B^+(\vx_1) \cup
\ldots \cup B^+(\vx_l)$ as shown in Fig.~\ref{Fig:unionOfForwardCones}.
From a family of sets of points $\mathcal{F}=\{F_0,\ldots,F_{m-1}\}$,
such that $F_0=\{\vzero\}$ satisfying for every $i$:
1) $\forall \vy\in F_i,~\exists \vx \in F_{i-1}$ such that $\vx<\vy$, and
2) $\forall \vy\in F_i,~\forall \vx \in F_{i-1}, ~\vy \not < \vx$,
we can define a monotone partition of the form $\mathcal{P} = \{P_1, \dots, P_{m-1}\}$,
where $P_i = B^+(F_{i-1})-B^+(F_i)$, see  Fig.~\ref{Fig:aPartition}.

\begin{figure}
\begin{subfigure}[t]{.3\textwidth}
\centering
\scalebox{.55}{\input{./Figures/cones/forwardAndBackwardCones}}
\caption{Backward and forward cone for $\vx$}
\label{Fig:forwardAndBackwardCones}
\end{subfigure}
\begin{subfigure}[t]{.3\textwidth}
\centering
\scalebox{.55}{\input{./Figures/cones/unionOfForwardCones}}
\caption{Union of cones}
\label{Fig:unionOfForwardCones}
\end{subfigure}
\begin{subfigure}[t]{.3\textwidth}
\centering
\scalebox{.55}{\input{./Figures/cones/partition}}
\caption{An alphabet partition}
\label{Fig:aPartition}
\end{subfigure}

\caption{ }
\label{Fig:example_automaton2tree}
\end{figure}

\begin{figure}

  \begin{subfigure}[t]{.4\textwidth}
      \centering
      \scalebox{.55}{\input{./Figures/cones/SL_refine_partition_2}}
      \caption{ } \label{fig:part_ref_a}
  \end{subfigure}
  \begin{subfigure}[t]{.4\textwidth}
      \centering
      \scalebox{.55}{\input{./Figures/cones/SL_refine_partition_3}}
      \caption{ } \label{fig:part_ref_b}
  \end{subfigure}

   \caption{Modifying the alphabet partition for state $\sy{u}$ after receiving $u\cdot b \cdot v$ as counter-example.
   Letters above $b$ are moved from $[ \sy{a}]$ to $[ \sy{a}']$. }
\end{figure}

A subset $P$ of $\Sigma$, as defined above, may have several mutually-incomparable minimal
elements, none of which being dominated by any other element of $P$.
One can thus apply the symbolic learning algorithm but without the presence of
unique minimal evidence and minimal counter-example.
For this reason a symbolic word may have more than one evidence. Evidence
compatibility is preserved though due to the nature of the partition.

The teacher is assumed to return a counter-example chosen from a set of
incomparable minimal counter-examples. Like in the algorithm for totally ordered alphabet,
every counter-example either discovers a new state or refines a partition.
The learning algorithm for partially-ordered alphabets is similar to Algorithm~\ref{alg:symbolic}
and can be applied with only a minor modification in the treatment of the counterexamples
and specifically in the refinement procedure.
Lines 6-8 of Procedure~\ref{alg:TreatCex} should be ignored in the case where there
exists a symbolic letter $\sy{a}'$, as illustrated in Fig.~\ref{fig:part_ref_a}, such
that $\sy{f}(\sy{u}\cdot b \cdot e ) = \sy{f}(\sy{u} \cdot \sy{a}'  \cdot e )$ for all $e \in E$.
In such a case, function $\psi$ is updated as in line 9 by replacing $\anew$ by $\sy{a}'$ and $b$
should be added to $\mu(\sy{a}')$. In Fig.~\ref{fig:part_ref_b}, one can see
the partition after refinement, where all letters above $b$ have been moved from $[\sy{a}]$ to $[\sy{a}']$.

\begin{figure}[ht]
    \scalebox{.9}{\input{./Figures/Ex_SL3/SLex3_tables.tex}}
    \smallskip
    \caption{Observation tables for Example~\ref{ex:SLex3} }
    \label{fig:SLex3_tables}
\end{figure}

\begin{figure}[ht]
    \centering
\def\H#1 { \input{./Figures/Ex_SL3/SLex3_h#1} }
\scalebox{1}{
    \begin{tabular}{| c | c | c |}
\hline
   $\sy{A}_0$ & $\sy{A}_{1-3}$ & $\sy{A}_{4-7}$ \\
    \H{0} & \H{1} & \H{4} \\
\hline
\end{tabular}} \par
\scalebox{1.12}{
\begin{tabular}{| c | c |}
   $\sy{A}_9$ & $\sy{A}_{10-11}$  \\
   \H{8}  & \H{9}  \\
\hline
\end{tabular}}\par
\scalebox{1.12}{
\begin{tabular}{| c | c |}
   $\sy{A}_{12-15}$ & $\sy{A}_{16-18}$ \\
   \H{11}       & \H{15}       \\
\hline
\end{tabular}}
    \caption{Hypothesis automata for Example~\ref{ex:SLex3} }
    \label{fig:SLex3_hypotheses_automata}
\end{figure}

\begin{figure}[ht]
    \centering
\def\SLp#1 {\scalebox{.5}{\input{./Figures/Ex_SL3/SLex3_all_psi/SLex3_psi#1} }}
\begin{tabular}{r l}
  $\psi_0$ & \SLp{0_a0} \SLp{1_a1} \\
  $\psi_1$ & \SLp{0_a0a2_a} \SLp{1_a1} \\
  $\psi_2$ & \SLp{0_a0a2_b} \SLp{1_a1} \\
  $\psi_3$ & \SLp{0_a0a2} \SLp{1_a1} \\
\end{tabular}
\begin{tabular}{r l}
  $\psi_4$ & \SLp{0_a0a2} \SLp{1_a1a3_a} \\
  $\psi_5$ & \SLp{0_a0a2} \SLp{1_a1a3_b} \\
  $\psi_6$ & \SLp{0_a0a2} \SLp{1_a1a3_c} \\
  $\psi_7$ & \SLp{0_a0a2} \SLp{1_a1a3} \\
\end{tabular}
\caption{Alphabet partition for Example~\ref{ex:SLex3} (part 1)}
    \label{fig:SLex3_psi2}
\end{figure}

 \begin{figure}
 \ContinuedFloat
    \centering
\def\SLp#1 {\scalebox{.5}{\input{./Figures/Ex_SL3/SLex3_all_psi/SLex3_psi#1} }}
\begin{tabular}{rl}
  $\psi_8$ & \SLp{0_a0a2} \SLp{1_a1a3} \SLp{2_a4}  \\
  $\psi_9$ & \SLp{0_a0a2} \SLp{1_a1a3} \SLp{2_a4} \SLp{3_a5} \\
  & \multicolumn{1}{c}{\vdots}   \\
  $\psi_{11}$ & \SLp{0_a0a2} \SLp{1_a1a3} \SLp{2_a4a6} \SLp{3_a5} \\
  & \multicolumn{1}{c}{\vdots}   \\
  $\psi_{15}$ & \SLp{0_a0a2} \SLp{1_a1a3} \SLp{2_a4a6a7} \SLp{3_a5} \\
  & \multicolumn{1}{c}{\vdots}   \\
  $\psi_{18}$ & \SLp{0_a0a2} \SLp{1_a1a3} \SLp{2_a4a6a7a8} \SLp{3_a5} \\
\end{tabular}

\caption{Alphabet partition for Example~\ref{ex:SLex3} (part 2)}
    \label{fig:SLex3_psi}
\end{figure}

\begin{exa}\label{ex:SLex3}
Let us illustrate the learning process for a target language $L$ defined over $\Sigma = [0,100]^2$.
All tables, hypotheses automata and alphabet partitions for this example are
shown in Figures \ref{fig:SLex3_tables}, \ref{fig:SLex3_hypotheses_automata},
and \ref{fig:SLex3_psi}, respectively.

The learner starts asking MQs for the empty word. A symbolic letter $\sy{a}_0$ is
chosen to represent its continuations with the minimal element of
$\Sigma$ as evidence, i.e., $\mu(\sy{a}_0) = \binom {0} {0}$. The symbolic word $\sy{a}_0$ is moved to
$\sy{S}$ for the table $\sy{T}_0$ to be closed.
The symbolic letter $\sy{a}_1$ is added to the alphabet of state $\sy{a}_0$, and the learner asks a MQ for $\binom {0} {0}
\binom {0} {0}$, the evidence of the symbolic word $\sy{a}_0 \sy{a}_1$. The first
hypothesis automaton is $\sy{\mathcal{A}}_0$ with $\Sigma$-semantics $[\sy{a}_0] = [\sy{a}_1] = \Sigma$.
The counter-example $(\binom {45} {50}, -)$ refines the partition
for the initial state. The symbolic alphabet is extended to $\sy{\Sigma}_{\epsilon} =
\{\sy{a}_0, \sy{a}_2\}$ with $[\sy{a}_2] = \{x>=\binom {45}{50}\}$,
$[\sy{a}_0] = \Sigma - [\sy{a}_2]$, and $\mu(\sy{a}_2) = \binom {45}{50}$.
The new observation table and hypothesis are $\sy{T}_1$ and
$\sy{\mathcal{A}}_1$. Two more counter-examples will come to refine the partition for the
initial state, $(\binom {60} {0}, -)$ and $(\binom {0} {70}, -)$, that will
modify the partition for the initial state, moving all letters greater than
$\binom {60} {0}$ and $\binom {0} {70}$ to the $\Sigma$-semantics of
$\sy{a}_2$ as can be seen in $\psi_2$ and $\psi_3$ respectively.

After the hypothesis $\sy{\mathcal{A}}_3$, the counter-example ($\binom {0} {0} \binom {0}
{80}, -)$ adds a new symbol $\sy{a}_3$ and a new transition
in the hypothesis automaton. The counter-examples that follow, namely, $(\binom
{0} {0} \binom {80} {0},-)$, $(\binom{0}{0}\binom{40}{15},-)$, and
$(\binom{0}{0}\binom{30}{30},-)$ refine the $\Sigma$-semantics for symbols in
$\sy{\Sigma}_{\sy{a}_0}$ as shown in $\psi_{4-7}$.

Then counter-example $(\binom {45}{50} \binom {0} {0},+)$ is presented.
As we can see, the prefix $\binom{45}{50}$ exist already in $\mu(\sy{a}_2)$ and
$\sy{a}_2\in\sy{R}$ which means $\sy{a}_2$ becomes a state, and to distinguish it from
the state represented by the empty word the learner adds to $E$ the suffix
of the counter-example $\binom {0}{0}$. The resulting table $\sy{T}_8$ is not closed
and $\sy{a}_0\sy{a}_1$ is moved to $\sy{S}$. The new table $\sy{T}_9$ is
closed and evidence compatible. The hypothesis $\sy{\mathcal{A}}_9$ has now four states and
the symbolic alphabet and $\Sigma$-semantics for each state can be seen in $\psi_9$.
The counter-examples that follow will refine the partition at state $\sy{a}_2$. The
new transitions discovered and all refinements are shown in $\sy{\mathcal{A}}_{10-18}$
and $\psi_{10}-\psi_{18}$. The language was learned using $20$ membership queries
and 17 counter-examples.  \qed
\end{exa}

\section{On Complexity}\label{S:complexity}

The complexity of the symbolic algorithm is influenced not by the size of
the alphabet but by the resolution (partition size) with which we observe it.
Let $L\subset\Sigma$ be the target language and let $\sy{\mathcal{A}}$ be the minimal
symbolic automaton recognizing this language with state set $Q$ of size $n$ and a
symbolic alphabet $\sy{\Sigma} = \biguplus_{q}\sy{\Sigma}_q$ such that $|\sy{\Sigma}_q|\leq m$
for every $q$.

Each counter-example improves the hypothesis in one out of two ways.
Either a new state is discovered or a partition gets refined.
Hence, at most $n-1$ equivalence queries of the first type can be asked and $n(m-1)$ of the second,
resulting in $\mathcal{O}(mn)$ equivalence queries.

Concerning the size of the table, the set of prefixes $\sy{S}$ is monotonically increasing
and reaches the size of exactly $n$ elements.
Since the table, by construction, is always kept
reduced, the elements in $\sy{S}$ represent exactly the states of the
automaton. The size of the boundary is always smaller than the total number of
transitions in the automaton, that is $mn-n+1$. The number of suffixes in $E$, playing a
distinguishing role for the states of the automaton, range between
$\log_2n$ and $n$. Hence, the size of the table ranges between
$(n+m)\log_2n$ and $n(mn + 1)$.

For a totally ordered alphabet
the size of the concrete sample coincides with the size of the symbolic sample
associated with the table and hence the number of membership queries asked is $\mathcal{O}(mn^2)$.
For a partially ordered alphabet with
each $F_i$ defined by at most $l$ points, some additional queries
are asked. For every row in $\sy{S}$, at most $n(m-1)(l-1)$ additional
words are added to the concrete sample, hence more membership queries might
need to be asked. Furthermore, at most $l-1$ more counter-examples are given to
refine a partition.
To conclude, the number of queries in total asked to learn language $L$
is $\mathcal{O}(mn^2)$ if $l< n$ and $\mathcal{O}(lmn)$ otherwise.

\section{Conclusion}\label{S:discussion}

We have defined a generic algorithmic scheme for automaton learning, targeting  languages over large alphabets that can be recognized by finite symbolic automata having a modest number of states and transitions. Some ideas similar to ours have been proposed for the particular case of parametric languages  \cite{BergJR06} and recently in a more general setting \cite{alph-refinement,local-alph,bb13sigma} including partial evidential support and alphabet refinement during the learning process.

The genericity of our algorithm is due to a semantic approach (alphabet partitions) but of course, each and every domain will have its own semantic and syntactic specialization in terms of the size and shape of the alphabet partitions. In this work we have implemented an instantiation of this scheme for alphabets such as $(\mathbb{N}, \leq)$ and $(\mathbb{R},\leq)$.
When dealing with numbers, the partition into a finite number of intervals (and monotone sets in higher dimensions) is very natural and used in many application domains ranging from quantization of sensor readings to income tax regulations. It will be interesting to compare the expressive power and succinctness of symbolic automata with other approaches for representing numerical time series and to compare our algorithm with other inductive inference techniques for sequences of numbers.

As a first excursion into the domain, we have made quite strong assumptions on the nature of the equivalence oracle, which, already for small alphabets, is a bit too strong and pedagogical to be realistic. We assumed that it provides the shortest counter-example and also that it chooses always the minimal available concrete symbol. We can relax the latter (or both) and even omit this oracle altogether and replace it by random sampling, as already proposed in \cite{Angluin87} for concrete learning.
Over large alphabets, it might be even more appropriate to employ probabilistic convergence criteria a-la \emph{PAC learning} \cite{valiant1984theory} and be content with a correct classification of a large fraction of the words, thus tolerating imprecise tracing of boundaries in the alphabet partitions.
This topic is subject to ongoing work. Another challenging research direction is the adaptation of our framework to languages over Boolean vectors.

\section*{Acknowledgement}
This work was supported by the French project EQINOCS (ANR-11-BS02-004). We thank Peter Habermehl, Eugene Asarin and anonymous referees for useful comments and pointers to the literature.

\bibliographystyle{alpha}


\section{Introduction}

Confirmation of CP violation in $B$ meson decays through the measurement
of the time-dependent decay rate asymmetry has demonstrated the power of
the high luminosity $B$ factories, Belle at KEKB, KEK and BaBar at
PEP-II, SLAC.  Together with measurements of the angles and sides of the
Unitarity Triangle, the picture of CP violation through the
Kobayashi-Maskawa mechanism has been established to be at least the
dominant source of all CP violating phenomena in the high energy physics
known to date.  This was possible only by building the ``$B$ factories''
with two orders of magnitude higher luminosity than existing facilities
at that time, and with a new concept of the boosted center-of-mass frame
with asymmetric beam energies for an $e^+e^-$ collider.  The $B$
factories have also provided a rich field for many other non-trivial
tests of the Standard Model (SM) with their power based on a huge
statistics of $B$ decays, $D$ decays and $\tau$ decays.

However, in spite of its success, the SM is still considered to be a low
energy approximation of a more fundamental physics beyond the SM (BSM)
for many reasons. For example, CP violation in the SM cannot explain the
baryon number asymmetry in the universe; another more theoretical
argument is that BSM physics is expected to lie at the TeV energy scale
in order to solve the hierarchy problem. On the other hand, there is a
mystery called the flavor problem: a new interaction around a TeV energy
scale would alter the flavor changing neutral current amplitudes and a
large deviation due to BSM would be expected, unless the coupling
constants are fine tuned or aligned to the SM couplings to reconcile
with the strong constraints from $B$ factory measurements.

BSM effects should appear in most cases through loop diagrams, while
the tree diagrams are usually unaffected. To observe the effects on
the Unitarity Triangle of different contributions of loop and tree
diagrams, and also through other rare phenomena, it is again necessary
to build a new facility with a further two orders of magnitude
higher luminosity than now. This is the motivation for a ``super'' $B$
factory.

\def{\cal S}{{\cal S}}
\def{\cal A}{{\cal A}}
\defV_{ub}{V_{ub}}
\defV_{cb}{V_{cb}}
\defV_{tb}{V_{tb}}
\defV_{td}{V_{td}}
\def\overline{u}{}{\overline{u}{}}
\def\overline{c}{}{\overline{c}{}}
\def\overline{q}{}{\overline{q}{}}
\defb\to c{b\to c}
\defb\to u{b\to u}
\defb\to s{b\to s}
\defb\to d{b\to d}
\defb\to c\cbar s{b\to c\overline{c}{} s}
\defb\to s\qbar q{b\to s\overline{q}{} q}
\defb\to c\ell\nu{b\to c\ell\nu}
\defb\to u\ell\nu{b\to u\ell\nu}
\defB\to X_u\ell\nu{B\to X_u\ell\nu}
\defB\to \pi\ell\nu{B\to \pi\ell\nu}
\def\pi^\pm{\pi^\pm}
\def\pi^+{\pi^+}
\def\pi^-{\pi^-}
\def\pi^0{\pi^0}
\defK^0{K^0}
\defK^0_S{K^0_S}
\defK^0_L{K^0_L}
\defJ/\psi{J/\psi}
\defD^0{D^0}
\def\overline{D}{}{\overline{D}{}}
\def\Dbar^0{\overline{D}{}^0}
\def\DZ\DZbar{D^0\Dbar^0}
\defB^0{B^0}
\def\overline{B}{}{\overline{B}{}}
\def\BZ\Bbar^0{B^0\overline{B}{}^0}
\defB\to\Jpsi\KS{B\to\JpsiK^0_S}
\defB\to\piP\piM\piZ{B\to\pi^+\pi^-\pi^0}
\defB\to\piP\piM{B\to\pi^+\pi^-}
\defB\to\pi\pi{B\to\pi\pi}
\defB\to\rho\pi{B\to\rho\pi}
\defB\to\rho\rho{B\to\rho\rho}
\defB\to\phi\KZ{B\to\phiK^0}
\defB\to\eta'\KZ{B\to\eta'K^0}
\defB\to\KS\KS\KS{B\toK^0_S\KSK^0_S}
\defB\to\tau\nu{B\to\tau\nu}
\defB\to D^{(*)}\tau\nu{B\to D^{(*)}\tau\nu}
\defB\to\mu\nu{B\to\mu\nu}
\defB\to D^0K{B\to D^0K}
\def\;{\rm ab}^{-1}{\;{\rm ab}^{-1}}
\def{\rm cm}^{-2}{\rm s}^{-1}{{\rm cm}^{-2}{\rm s}^{-1}}
\def\EM#1{\times10^{-#1}}
\def\EP#1{\times10^{#1}}

                        \section{Physics Programs}

The key measurement at a super $B$ factory will still be the
measurement of the Unitarity Triangle, but with a precision an order
of magnitude better than what we have now. There are also a large
number of other potential measurements that are sensitive to BSM, and
their importance will be more significant than has been the case in
Belle and BaBar. More thorough and detailed studies can be found in
\cite{superkekb-loi,superb-cdr,sff,yellow-report}.

\subsection{Unitarity Triangle}

The current world average on the angle $\phi_1$ of the Unitarity
Triangle\footnote{In this report, the notation $\phi_1$, $\phi_2$,
  $\phi_3$ is used instead of $\beta$, $\alpha$ and $\gamma$.} has a
remarkable precision, $\phi_1=(21.1\pm0.9)^\circ$~\cite{hfag2008},
where the error is dominated by the results from the two $B$ factories
using the sum of the datasets exceeding $1\;{\rm ab}^{-1}$. Measurement of this
and other angles, and the sides of the Triangle were made possible
only after the $B$ factories came online. All the results so far are
found to be consistent with each other. However, they are not precise
enough yet to identify any possible discrepancy, for example in the
$CP$ violating phase measured in the loop diagrams in which BSM
effects could reside, from the phase measured from tree diagrams in
which BSM effects are not expected.

The angle $\phi_1$ is measured in the form of $\sin2\phi_1$, which is
the coefficient of the sine term (${\cal S}$) in the time-dependent $CP$
asymmetry that appears due to an irreducible complex phase in the
$\BZ\Bbar^0$ mixing when measured together with the $b\to c\cbar s$ transition
into a $CP$ eigenstate such as $\JpsiK^0_S$.  At this moment the measurement
of $\sin2\phi_1$ is still slightly statistical error dominated.  An
early dataset of $5\;{\rm ab}^{-1}$ from a super $B$ factory will turn this into
an ultimate measurement of $\sin2\phi_1$ with an error of $0.015$ (or
$0.6^\circ$ in terms of $\phi_1$).  The precision of the measurement
then matches the theoretical uncertainty, which appears due to the
effects of subdominant diagrams with the same final state, a complex
phase different from $\phi_1$ and an unknown size of the amplitude.

The angle $\phi_2$ appears in the combination of the $\BZ\Bbar^0$ mixing
and the $b\to u$ transition into a $CP$ eigenstate such as
$B\to\piP\piM$. Unfortunately, $\sin2\phi_2$ cannot be directly measured
from the time-dependent asymmetry of $B\to\piP\piM$ due to the $b\to d$
penguin contribution which has a different weak phase. The amplitude
of such a contribution and the angle $\phi_2$ have to be extracted
from measurements of all $\pi\pi$ charge combinations ($\pi^+\pi^-$,
$\pi^\pm\pi^0$, $\pi^0\piZ$) by assuming isospin symmetry. The same is
possible with $B\to\rho\rho$, or a more elaborate technique can be
performed to disentangle the amplitudes and phases of $B\to\rho\pi$
using a time-dependent Dalitz analysis of $B\to\piP\piM\piZ$. Multiple
solutions appear in these procedures and they make it difficult to
pinpoint the value of $\phi_2$; the current $1\sigma$ interval from
combined Belle and BaBar results is $[83.5, 94.0]^\circ$, e.g.,
in~\cite{ckmfitter}. A super $B$ factory will significantly improve
the situation as the correct solution will become unambiguous from the
three independent measurements. The combined error for $\phi_2$ is
about $2^\circ$ with $5\;{\rm ab}^{-1}$ data. This is the ultimate precision at
which the experimental error matches the model uncertainty of the
Dalitz amplitudes or theoretical uncertainty due to isospin breaking
effects.

At a super $B$ factory, the set of angles $\phi_1$ and $\phi_2$,
already with $5\;{\rm ab}^{-1}$, provides a reference ``point'' of the
Unitarity Triangle with a 2\% error. All of the other possible
measurements will be used to search for a deviation of $O(10\%)$ from
the SM.

\subsection{Deviation from the Unitarity Triangle}

The three most promising measurements to search for a deviation from
expectation for the Unitarity Triangle variables are; the angle
$\phi_1$ from loop mediated $b\to s$ decays, the angle $\phi_3$ from
the tree process $B\to D^0K$, and the length of the side $|V_{ub}|$ using
$b\to u\ell\nu$ decays. Any deviation from the reference point defined by
$(\phi_1, \phi_2)$ becomes evidence of BSM.

In the SM, the size of the time dependent $CP$ asymmetry ${\cal S}$ in
the $b\to s\qbar q$ decay modes into a $CP$ eigenstate is the same as that
in $b\to c\cbar s$, i.e.\ $\sin2\phi_1$, as both diagrams have the same weak
phase. Since $b\to s\qbar q$ is a penguin loop, the phase can be modified by
an additional BSM amplitude if it exists, while it is unchanged in
$b\to c\cbar s$. Therefore, the deviation in ${\cal S}$ from $\sin2\phi_1$ is
the sign of BSM. For a given final state, there are always subdominant
diagrams, e.g., the tree diagram $b\to u$ with $s\overline{u}{}$, which are the
source of possible modification of ${\cal S}$ within the SM. Three modes,
$B\to\phi\KZ$, $B\to\eta'\KZ$ and $B\to\KS\KS\KS$, are considered to be the
golden modes with the smallest of such pollutions, estimated to be
about 0.02. Measurements will be statistical error dominated until
$50\;{\rm ab}^{-1}$ or more integrated luminosity is obtained, as shown in
Fig.~\ref{fig:btoscpv}. The expected errors are, 0.02, 0.03 and 0.04
for $B\to\eta'\KZ$, $B\to\phi\KZ$ and $B\to\KS\KS\KS$, respectively, at
$50\;{\rm ab}^{-1}$.

\begin{figure}[h]
\centering
\includegraphics[width=80mm]{figure1.eps}
\caption{Expected sensitivities of the CP violation measurements in
  $B\to\eta'\KZ$, $B\to\phi\KZ$ and $B\to\KS\KS\KS$ decays as a function of the
  integrated luminosity at SuperKEKB.  } \label{fig:btoscpv}
\end{figure}

The angle $\phi_3$ is most cleanly measured using $B\to D^0K$ decays.
There, $\phi_3$ appears as interference between the tree amplitude
$b\to c$ with $d\overline{u}{}$ and another tree amplitude $b\to u$ with $d\overline{c}{}$.
The former gives $\Dbar^0$ in the final state while the latter gives
$D^0$; common final states between $D^0$ and $\Dbar^0$ decays are the
source of interference between these two decay channels.  As there is no
subdominant amplitude with a loop diagram, this provides the cleanest SM
measurement.  There are several methods depending on different $D^0$
decay modes, e.g., $D^0$ decaying into a $CP$ eigenstate, or into a doubly
Cabibbo suppressed final state.  The most effective method is based on
the Dalitz analysis of the decay chain $B^\pm\to D K^\pm$; $D\to
K^0_S\pi^+\pi^-$.  The analysis depends on the model of the three-body $D$
decay amplitudes, and gains significantly from charm factory data with
CP-tagged $D^0$ decays.  The combined $\phi_3$ error will be $6^\circ$
at $5\;{\rm ab}^{-1}$, or $2^\circ$ at $50\;{\rm ab}^{-1}$.

The $|V_{ub}|$ measurement is performed using either an inclusive
measurement of $B\to X_u\ell\nu$ or an exclusive one such as $B\to \pi\ell\nu$.
Currently, both measurements have a similar size in the error, and
have some tension between the results. Both methods provide the
cleanest results using a tagging technique of reconstructing a
hadronic $B$ decay mode for the other $B$ meson decay. The tagging
efficiency is not very high and demands huge statistics which is
suitable at a super $B$ factory. Since only a limited kinematical
range can be measured due to the huge $b\to c\ell\nu$ background, the
inclusive measurement requires the operator product expansion
technique to extrapolate into the full kinematical range. All the
necessary information is available from data, and the total error will
be 6\% at $5\;{\rm ab}^{-1}$ and 4\% at $50\;{\rm ab}^{-1}$. The exclusive branching
fraction will be more accurately measured at a super $B$ factory. If
the $B\to\pi$ form factor is calculated using lattice QCD more
precisely, $|V_{ub}|$ will be determined from the exclusive measurement
with a smaller error.

\begin{figure}[h]
\centering
\includegraphics[width=80mm]{figure2.eps}
\caption{Expected sensitivities of the Unitarity Triangle measurements
  at $50\;{\rm ab}^{-1}$ data at SuperKEKB.

  } \label{fig:rhoeta50}

\end{figure}

Expected sensitivities of the Unitarity Triangle measurements at
$50\;{\rm ab}^{-1}$ data at SuperKEKB is shown in Fig.~\ref{fig:rhoeta50} using
the current world average values for the central values.
Given these measurements, a 10\% deviation in any of these measurement
would be identified at a super $B$ factory with $50\;{\rm ab}^{-1}$.

\subsection{More Key Measurements}

There are many other key measurements which can be used to search for
BSM in $B$ decays, and also in decays of $D$ mesons and $\tau$ leptons,
which are equally abundantly produced at a super $B$ factory.

The weak interaction which governs $b$ quark decays is based on a
left-handed current in the limit of massless quarks. This is not
necessarily the case in many BSM models. The right-handed current in
the $b\to s$ transition can be effectively identified as a non-zero
${\cal S}$ value in a time-dependent CP measurement of
$B\toK^0_S\pi^0\gamma$. With $50\;{\rm ab}^{-1}$ the error will be less than $3\%$
and already better than the theoretical uncertainty on the deviation
of ${\cal S}$ from zero due to the finite mass of the $s$ quark.

Many BSM models also require more than one Higgs doublet, including a
charged Higgs boson. The charged Higgs boson can replace the weak
boson in a tree diagram, and its effect is enhanced in the helicity
suppressed purely leptonic decays and semi-leptonic decays with a
$\tau$ lepton. The effect can be searched for through a deviation from
expectation in the branching fraction of $B\to\tau\nu$. Similar
measurements can be performed with $B\to D^{(*)}\tau\nu$ and $B\to\mu\nu$.
If deviations are observed in all these modes, a comparison between
them leads to a test of the universality of the coupling, and provides
stronger evidence for the existence of the charged Higgs boson.

Inclusive measurements such as $B\to X_s\gamma$, $B\to X_d\gamma$ and
$B\to X_s\ell^+\ell^-$ are also sensitive to a wide range of BSM.
Especially, the zero-crossing point of the forward-backward asymmetry in
$B\to X_s\ell^+\ell^-$ has a very clean signature.

The recently observed large values of the $\DZ\DZbar$ mixing parameters
$(x,y)$, of the order $10^{-2}$, suggest the possibility of a BSM
contribution, while an explanation within the SM is not excluded because
of a large hadronic uncertainty.  A measurement of $CP$ violation in
$\DZ\DZbar$ mixing would be clear evidence for a BSM effect in the charm
quark sector.

Finally, lepton flavor violating $\tau$ decay is also allowed in many
BSM models, while it is not allowed at all in the SM. There are a
large number of possible lepton flavor violating decay modes (e.g.,
$\tau\to\mu\gamma$, $\tau\to\mu \eta$ or $\tau\to e^+e^-e^+$) which
have been and will be searched for. If observed, it will be an
unambiguous sign of new physics.

\subsection{Comparison with LHCb}

There may be a question why we have to build a super $B$ factory while
the next generation flavor physics can be studied at LHCb. In reality,
it is almost impossible to measure modes with photons, $\pi^0$ and
neutrinos, and perform inclusive measurements at LHCb. Many of
these are the key measurements to study BSM as already discussed.

There are examples where LHCb has an excellent sensitivity: the
Unitarity Triangle parameters, especially the angle $\phi_3$, can be
precisely measured at LHCb with a similar precision to that of at a
super $B$ factory, provided that the systematic errors are under
control. In order to search for a BSM $CP$ phase in the $b\to s$
transition, $B_s\to\phi\phi$ can be used; in order to search for the
right-handed current, $B_s\to\phi\gamma$ can be used. These are
different decay modes related to searches for the same type of BSM
effects, and the searches at the two places are extremely helpful for
gaining an unambiguous understanding of BSM physics.

\section{Next Generation B Factories}

In order to collect an integrated luminosity of $50\;{\rm ab}^{-1}$ within a
reasonable amount of running time, the instantaneous luminosity has to
be above or at least close to $10^{36}{\rm cm}^{-2}{\rm s}^{-1}$. In addition, to keep
synergy with energy frontier physics at the LHC and flavor physics at
LHCb, it is crucial to operate the super $B$ factory in the next
decade.

Currently, two projects are planned: the SuperKEKB project in Japan and
the SuperB project in Italy.  If resources allow, it is definitely
better to have both facilities for healthy competition and cross-checks,
as was extremely helpful in the case of competition between Belle
and BaBar.  However, under the current situation for high energy
physics, it does not seem to be possible to have both of them at the
same time.

Key parameters for a high luminosity are the beam current ($I$) and the
beam-beam parameter ($\xi_y$) that are proportional to the instantaneous
luminosity, and the vertical $\beta$ function at the interaction point
($\beta_y^*$) which is inversely proportional to the luminosity.  The
two projects take different approaches for a higher luminosity.  Typical
parameters for SuperKEKB are beam currents of 9.4 A $\times$ 4.1 A,
$\xi_y>0.24$ and $\beta_y=3.0$ mm for both rings.  Those for SuperB are
1.85~A $\times$ 1.85~A beam currents, $\xi_y=0.15$ and
$\beta_y=0.39/0.22$ mm for the high/low energy ring.  An example of the
parameters is given in Table~\ref{tbl:superkekb-superb}.  These
parameters give instantaneous luminosities of $0.8\EP{36}{\rm cm}^{-2}{\rm s}^{-1}$ for
SuperKEKB and $1.0\EP{36}{\rm cm}^{-2}{\rm s}^{-1}$ for SuperB, almost two orders of
magnitude higher than the current KEKB record, $0.017\EP{36}{\rm cm}^{-2}{\rm s}^{-1}$.

\def\twoc#1{\multicolumn{2}{c}{#1}}

\begin{table}[h]
\begin{center}
\caption{An Example of machine parameters for SuperKEKB and SuperB.}
\label{tbl:superkekb-superb}
\begin{tabular}{lcccccc}
    \hline
    & & \twoc{SuperKEKB} & & \twoc{SuperB} \\
    \hline
    && ($e^+$) & ($e^-$) && ($e^+$) & ($e^-$) \\
    Energy (GeV)      && 3.5 & 8     && 4 & 7 \\
    Luminosity
          ($10^{36}$) && \twoc{0.55}  && \twoc{1.0} \\
    Number of bunches && \twoc{5018} && \twoc{1251} \\
    Beam current (A)  && 9.4 & 4.1   && 1.85 & 1.85 \\
    $\beta(y^*)$ (mm) &&  \twoc{3}        && 0.22 & 0.39 \\
    $\beta(x^*)$ (mm) &&  \twoc{200}      && 35 & 20 \\
    emittance $\epsilon(y)$ (pm.rad) && 60 & 66 && 7   & 4   \\
    emittance $\epsilon(x)$ (nm.rad) && 12 & 13 && 2.8 & 1.6 \\
    beam-size $\sigma(x^*)$ ($\mu$m) && 37.5 & 39.8 && 0.039 & 0.039 \\
    beam-size $\sigma(y^*)$ ($\mu$m) && 2.11 & 2.28 && 9.9 & 5.66 \\
    bunch length           && \twoc{3}    &&     &      \\
    Damping time (ms) && 84/-- & 47/-- && 40/20 & 40/20 \\
    Touschek lifetime (min)        &&   &   && 20 & 40 \\
    Beam lifetime (min)  &&   &   && 5.0 & 5.7 \\
    tune-shift $\xi(y)$ && \twoc{0.296} && \twoc{0.15} \\
    tune-shift $\xi(x)$ && \twoc{0.153} && 0.0043 & 0.0025 \\
    RF power (MW)            && & && \twoc{17} \\
    \hline
  \end{tabular}
\end{center}
\end{table}

\subsection{SuperKEKB}

The SuperKEKB project is an upgrade of the current KEKB facility at the
same place, reusing a large fraction of the existing components and
infrastructure.

One of the key components of SuperKEKB is the ``crab'' cavity that
rotates the envelope of the beam bunch and makes head-on collisions
possible for beams incident at a finite angle (crab-crossing). This will
at least geometrically increase the effective volume of the collision.
According to a simulation, the effect is more dramatic: the beam-beam
force becomes nearly independent of the horizontal coordinate at a half
integer tune. In the case of KEKB with a 22 mrad crossing angle, $\xi_y$
becomes 0.15 and almost doubles the luminosity, and for SuperKEKB with a
30 mrad crossing angle, $\xi_y>0.24$ is possible.

With this simulation result, KEKB has installed a crab cavity for each
of high and low energy rings and has been commissioning since 2007.
Under a low beam current operation, the specific luminosity reached
the predicted value (Fig.~\ref{fig:speclumi-crab}), and an enhancement
in the beam-beam parameter, $\xi_y=0.092$, with respect to the case
before the crab cavity, $\xi_y=0.056$, was observed. However, there is
a drop in the luminosity under a high beam current, and the reason is
still being investigated. In addition, the current crab cavity has to
be operated at a lower beam current than what was already achieved
without, and this has prevented the expected boost in the
instantaneous luminosity so far. The commissioning will continue for
one more year until the end of the KEKB running time.

The other key issue is the higher beam current. In order to store a
higher beam current without being affected by the electron cloud, the
vacuum pipe will be replaced all over the ring with antechamber type
beampipes, and the bellows with higher-current-proof ones.

The KEKB upgrade plan is already included in KEK's five-year roadmap
from 2009 to 2013. This includes a three-year shutdown time for the
construction.

\begin{figure}[h]
\centering
\includegraphics[width=80mm]{figure3.eps}
\caption{Specific luminosity simulated and measured with and without the
crab cavity at KEKB.} \label{fig:speclumi-crab}
\end{figure}

\subsection{Italian SuperB}

The SuperB project in Italy is a completely new project, with an ultra
low emittance approach inspired by the International Linear Collider
(ILC) project.  In order to achieve a very high luminosity with a
moderate beam current, both beams have to be squeezed into an extremely
small interaction region with a vertical size of 39 nm, and with a very
small $\beta_y^*$.  Such a beam could be possible, according to the
studies for the ILC dumping ring.  However, it does not necessary mean
that such a small emittance can be sustained while making collisions at
every turn with a very high luminosity.  The other problem would be the
very short beam lifetime of about only five minutes.

The ultra-small beamsize also implies a huge hourglass effect, and it
has to be suppressed either by making the bunch length extremely
short, which is not realistic, or by moving the vertical waist
positions of both beams along the $z$ axis with a proper phase. The
latter is called the ``crab waist'', and can be realized with a
sextupole magnet. The concept of the crab waist has been successfully
tested at DA$\Phi$NE at a low energy and low beam current, as shown in
Fig.~\ref{fig:dafne-2008may}.

\begin{figure}[h]
\centering
\includegraphics[width=80mm]{figure4.eps}
\caption{Luminosity improvement with the crab waist scheme measured at
  DA$\Phi$NE.} \label{fig:dafne-2008may}
\end{figure}

The other consideration at SuperB is to make the energy asymmetry
smaller, in order to save on the electricity bill. This makes the
resolution of the time difference between two $B$ meson vertices
worse, but it gives a better hermeticity, which is crucial for
measurements with neutrinos.

The candidate site is at the Tor Vegarta campus of INFN Rome.  Here
also, many components, including magnets, will be brought from PEP-II to
minimize the cost.

\section{Detector Considerations}

A high luminosity brings a high event rate. The $B$-pair events alone
will be delivered at a rate of 1 kHz under a luminosity of
$1\EP{36}{\rm cm}^{-2}{\rm s}^{-1}$, and the physics trigger rate will become 10 kHz
excluding the Bhabha events, which have an even higher rate. In order
to keep nearly 100\% efficiency for the $B$-pair events, the trigger
and data acquisition system have to be drastically improved. The
readout electronics also has to be as deadtime-free as possible.

A high luminosity brings a high background rate at the same time.  On
the other hand, to keep the advantage of the clean $e^+e^-$ environment
especially for measurements with photons, $\pi^0$ and neutrinos, any
performance drop with respect to the current Belle or BaBar detector
is not acceptable.

Since the existing Belle and BaBar detectors already have excellent
performance, it is not easy to drastically improve it, especially after
coping with the high background.

\subsection{SuperKEKB Detector}

The detector at SuperKEKB (SuperBelle) has to cope with the large
beam-gas background due to the much higher beam currents. After a
careful design of the beampipe and masks at the interaction region, it
is found that the size of Touschek background is moderate, and the
radiative-Bhabha background is not harmful except for the outmost
$K_L$ and muon detector. The total background will be about 20 times
that of the current conditions at Belle, and therefore a significant
amount of modification to the Belle detector is necessary.

\begin{figure}[h]
\centering
\includegraphics[width=80mm]{figure5.eps}
\caption{Comparison between the SuperBelle detector (upper) and the
  Belle detector (lower).} \label{fig:superbelle}
\vspace{12pt}
\end{figure}

\begin{figure}[h]
\centering
\includegraphics[width=80mm]{figure6.eps}
\caption{SuperB detector without (upper) and with (lower) optional
  detector components.} \label{fig:superb-det}
\end{figure}

In order to cope with the background, the following changes are
planned. The silicon vertex detector will have a larger radius with
six layers, with a possible option of a pixel detector for the
innermost layer. The enlarged vertex detector will replace the inner
part of the drift chamber and allow a larger volume for
$K^0_S\to\pi^+\pi^-$ vertexing. The drift chamber will be replaced with
one with smaller cell size to shorten the drift time and to reduce the
occupancy. The outer radius of the drift chamber will be enlarged,
thanks to the thinner outer detectors. The particle identification
devices will be fully replaced from existing time-of-flight counters
and the threshold-type aerogel Cherenkov counter, with a detector to
reconstruct the Cherenkov ring image, such as a time-of-propagation
counter for the barrel part and an aerogel ring-image counter for the
forward endcap part. The endcap part of the calorimeter will be
replaced with pure CsI crystals that have a faster time response,
while the thallium-doped CsI crystals will be unchanged for the barrel
part. The resistive plate counters for $K^0_L$ and muon detection will
be replaced with scintillation fibres.

\subsection{SuperB Detector}

Thanks to the smaller beam current, the beam-gas background is expected
to be moderate at the SuperB detector.  On the other hand, a huge
Touschek background is expected, and also the very short lifetime could
be harmful for the detector.

The detector is based on reuse of the existing BaBar detector, which
is already more immune to backgrounds than Belle.  However, similarly to
Belle's case, many of the components have to be replaced.  These
includes a new silicon vertex tracker, a new drift chamber, a new
forward calorimeter and a new $K^0_L$ and muon detection system.

\vspace*{12pt}

\section{Summary}

The physics program at a super $B$ factory is very compelling in the
integrated luminosity range between 5 to 50 $\;{\rm ab}^{-1}$.  This includes
the measurements of the precise reference point in the Unitarity
Triangle and possible deviations from there, extensive searches for
right handed currents, charged Higgs, lepton-flavor violating decays, and
many other search channels.

Both projects described in this paper are actively working on the
accelerator and detector designs. The design for SuperKEKB is already
finalizing for the production of necessary components, while the
SuperB design is also getting converged. We are looking forward to the
exciting future of flavor physics that will be possible at a super $B$
factory.

\bigskip