Problem Detail: I’m trying to answer this question: Let $S$ be the strings $langle P rangle$ accepted by the Turing Machine $P$ with input alphabet ${a,b}$, where $P$ accepts an infinite number of strings beginning with $a$ and a finite number Read More …
Author: ignougroup
[Solved]: Minimal Spanning tree and Prim’s Algorithm
Problem Detail: Is there any example that anybody could come up with that shows Prim’s algorithm does not always give the correct result when it comes knowing the minimal spanning tree. Asked By : fudu Answered By : Kaya For any un-directed graph Read More …
[Solved]: Why addition algorithm is not pseudo- polynomial?
Problem Detail: There is something I don’t understand. In the Subset Sum problem, in the Dynamic Programming solution, because of binary representation of the sum T, we say it is pseudo-polynomial in run time; we must sum in the worst case Read More …
[Solved]: Radix sort exercise
Problem Detail: I’m trying to understand a proof regarding radix-sort but to no avail. I’ll first write down a brief summary of the proof and then assign some questions which I hope will be clarified enough. Suppose you have an array Read More …
[Solved]: Weighted Set covering problem with a fixed number of colors
Problem Detail: I have a set of elements U = {1, 2, …. , n} and a set S of k sets whose union form the whole universe. Each of these sets is associated with a cost. I have a fixed Read More …
[Solved]: Is badly written code derogatory to the compiler?
Problem Detail: I was having a heated debate with a friend of mine (who considers me an idiot, mind you) and we were arguing about whether a compiler has an index, or coefficient, that judges how poorly code is written. Things Read More …
[Solved]: n log n = c. What are some good approximations of this?
Problem Detail: I am currently looking into Big O notation and computational complexity. Problem 1.1 in CLRS asks what seems a basic question, which is to get an intuition about how different algorithmic complexities grow with the size of the input. Read More …
[Solved]: How is Turing’s Solution to the Halting Problem Not Simply “Failure By Design”?
Problem Detail: I’m having a hard time viewing Turing’s solution to the Halting Problem as a logician, rather than as an engineer. Here is my understanding of the Halting Problem: Let $M$ be the set of all Turing Machines. Let $i$ Read More …
[Solved]: How do I verify that a DFA is equivalent to a NFA?
Problem Detail: I’m learning how to convert NFAs to DFAs and I want to make sure I’m doing it right. Obviously, going back in the other direction isn’t a thing. Does anyone know of an algorithm to check that a DFA Read More …
[Solved]: If a parser can parse a non-deterministic grammar, is the parser non-deterministic?
Problem Detail: I’ve written a recursive-descent parser generator, and I’m trying to classify it (call me a cowboy coder if you must). According to wikipedia, S → 0S0 | 1S1 | ε, which checks for an even-length palindrome, is a non-deterministic Read More …