26,658 research outputs found
Branch-coverage testability transformation for unstructured programs
Test data generation by hand is a tedious, expensive and error-prone activity, yet testing is a vital part of the development process. Several techniques have been proposed to automate the generation of test data, but all of these are hindered by the presence of unstructured control flow. This paper addresses the problem using testability transformation. Testability transformation does not preserve the traditional meaning of the program, rather it deals with preserving test-adequate sets of input data. This requires new equivalence relations which, in turn, entail novel proof obligations. The paper illustrates this using the branch coverage adequacy criterion and develops a branch adequacy equivalence relation and a testability transformation for restructuring. It then presents a proof that the transformation preserves branch adequacy
Pac-Learning Recursive Logic Programs: Efficient Algorithms
We present algorithms that learn certain classes of function-free recursive
logic programs in polynomial time from equivalence queries. In particular, we
show that a single k-ary recursive constant-depth determinate clause is
learnable. Two-clause programs consisting of one learnable recursive clause and
one constant-depth determinate non-recursive clause are also learnable, if an
additional ``basecase'' oracle is assumed. These results immediately imply the
pac-learnability of these classes. Although these classes of learnable
recursive programs are very constrained, it is shown in a companion paper that
they are maximally general, in that generalizing either class in any natural
way leads to a computationally difficult learning problem. Thus, taken together
with its companion paper, this paper establishes a boundary of efficient
learnability for recursive logic programs.Comment: See http://www.jair.org/ for any accompanying file
On the computational complexity of dynamic slicing problems for program schemas
This is the preprint version of the Article - Copyright @ 2011 Cambridge University PressGiven a program, a quotient can be obtained from it by deleting zero or more statements. The field of program slicing is concerned with computing a quotient of a program that preserves part of the behaviour of the original program. All program slicing algorithms take account of the structural properties of a program, such as control dependence and data dependence, rather than the semantics of its functions and predicates, and thus work, in effect, with program schemas. The dynamic slicing criterion of Korel and Laski requires only that program behaviour is preserved in cases where the original program follows a particular path, and that the slice/quotient follows this path. In this paper we formalise Korel and Laski's definition of a dynamic slice as applied to linear schemas, and also formulate a less restrictive definition in which the path through the original program need not be preserved by the slice. The less restrictive definition has the benefit of leading to smaller slices. For both definitions, we compute complexity bounds for the problems of establishing whether a given slice of a linear schema is a dynamic slice and whether a linear schema has a non-trivial dynamic slice, and prove that the latter problem is NP-hard in both cases. We also give an example to prove that minimal dynamic slices (whether or not they preserve the original path) need not be unique.This work was partly supported by the Engineering and Physical Sciences Research Council, UK, under grant EP/E002919/1
Unary Pushdown Automata and Straight-Line Programs
We consider decision problems for deterministic pushdown automata over a
unary alphabet (udpda, for short). Udpda are a simple computation model that
accept exactly the unary regular languages, but can be exponentially more
succinct than finite-state automata. We complete the complexity landscape for
udpda by showing that emptiness (and thus universality) is P-hard, equivalence
and compressed membership problems are P-complete, and inclusion is
coNP-complete. Our upper bounds are based on a translation theorem between
udpda and straight-line programs over the binary alphabet (SLPs). We show that
the characteristic sequence of any udpda can be represented as a pair of
SLPs---one for the prefix, one for the lasso---that have size linear in the
size of the udpda and can be computed in polynomial time. Hence, decision
problems on udpda are reduced to decision problems on SLPs. Conversely, any SLP
can be converted in logarithmic space into a udpda, and this forms the basis
for our lower bound proofs. We show coNP-hardness of the ordered matching
problem for SLPs, from which we derive coNP-hardness for inclusion. In
addition, we complete the complexity landscape for unary nondeterministic
pushdown automata by showing that the universality problem is -hard, using a new class of integer expressions. Our techniques have
applications beyond udpda. We show that our results imply -completeness for a natural fragment of Presburger arithmetic and coNP lower
bounds for compressed matching problems with one-character wildcards
Solomonoff Induction Violates Nicod's Criterion
Nicod's criterion states that observing a black raven is evidence for the
hypothesis H that all ravens are black. We show that Solomonoff induction does
not satisfy Nicod's criterion: there are time steps in which observing black
ravens decreases the belief in H. Moreover, while observing any computable
infinite string compatible with H, the belief in H decreases infinitely often
when using the unnormalized Solomonoff prior, but only finitely often when
using the normalized Solomonoff prior. We argue that the fault is not with
Solomonoff induction; instead we should reject Nicod's criterion.Comment: ALT 201
- ā¦