Problem Detail: Is the language $$L = {a,b}^* setminus {(a^nb^n)^nmid n geq1 }$$ context-free? I believe that the answer is that it is not a CFL, but I can’t prove it by Ogden’s lemma or Pumping lemma. Asked By : Andrés Felipe Read More …
Category: Uncategorized
[Solved]: Dijkstra algorithm: equal number of shortest paths
Problem Detail: If I had a Dijkstra graph with the number shortest paths from Node A to O being 1, would it be correct to say: the equal number of shortest paths from A to O is 1 and not 0, Read More …
[Solved]: Online generation of uniform samples
Problem Detail: A source provides a stream of items $x_1, x_2,dots$ . At each step $n$ we want to save a random sample $S_n subseteq { (x_i, i)|1 le i le n}$ of size $k$, i.e. $S_n$ should be a uniformly Read More …
[Solved]: A “natural” decidable problem not in $mathsf{NP}$?
Problem Detail: Are there any “natural” examples of decidable problems that are definitively known not to be in NP? The decidable languages I know of that are not contained in NP are usually derived from the time hierarchy theorem, which produces Read More …
[Solved]: Point Location Problem in Polygon in Repetitive Mode for a Simple Polygon
Problem Detail: I consider Point Location Problem in Polygon in repetitive mode in the case of simple polygon. In computational geometry,Point Location Problem in Polygon problem asks whether a given point in the plane lies inside, outside, or on the boundary Read More …
[Solved]: Isn’t Functional Programming just Imperative Programming in disguise?
Problem Detail: A YouTube video I was watching explained the differences between Imperative and Functional programming by demonstrating how the numbers from 1 to 10 are summed up in Java and in Haskell respectively. In Java, you must explicitly state each Read More …
[Solved]: Is this grammar really LL(1) while not being LR(1)?
Problem Detail: $S rightarrow S$, $L(G) = {}$ LL(1) analysis: We estabilish $FIRST(S)$ to be empty and $FOLLOW(S)$ to be ${$}$. $FIRST(S)$ doesn’t contain ε, so the parse table looks like this: +—+—+ | | $ | +—+—+ | S | Read More …
[Solved]: Big-O Notation of Anagram solution algorithm
Problem Detail: In Solution 1: Checking Off of Problem Solving with Algorithms and Data Structures, just beneath the ActiveCode: 1 extract (included at the bottom of this post for reference), it is stated: each of the n characters in s1 will Read More …
[Solved]: Are there complete problems for P and NP under other kinds of reductions?
Problem Detail: I know that the complexity class $mathsf{P}$ has complete problems w.r.t. $mathsf{NC}$ and $mathsf{L}$ reductions. Are these two classes the only possible classes of reductions under which $mathsf{P}$ has complete problems? Also, what classes of reduction can be used Read More …
[Solved]: How to solve an arrangement problem at the Archive Nationale of France using graph theory?
Problem Detail: Good evening! I’m actually doing an internship at the Archives Nationales of France and I encountered a situation I wanted to solve using graphs… I. The dusty situation We want to optimize the arrangement of books of my library Read More …