Problem Detail: I’ve seen circuit level implementations of ALU’s before, but how are NOT/AND/ADD performed mechanically? Asked By : Wuschelbeutel Kartoffelhuhn Answered By : slebetman Babbage’s arithmetic unit (ALU) for the Analytical Engine was originally called the mill. It wasn’t constructed out of Read More …
Author: ignougroup
[Solved]: Find k maximum numbers from a heap of size n in O(klog(k)) time
Problem Detail: I have a binary heap with $n$ elements. I want to get the $k$ largest elements in this heap, in $O(k log k)$ time. How do I do it? (Calling deletemax $k$ times yields a $O(k log n)$ complexity. Read More …
[Solved]: On “The Average Height of Planted Plane Trees” by Knuth, de Bruijn and Rice (1972)
Problem Detail: I am trying to derive the classic paper in the title only by elementary means (no generating functions, no complex analysis, no Fourier analysis) although with much less precision. In short, I “only” want to prove that the average Read More …
[Solved]: Restricted version of the Clique problem?
Problem Detail: Consider the following version of the Clique problem where the input is of size $n$ and we’re asked to find a clique of size $k$. The restriction is that the decision procedure cannot change the input graph into any Read More …
[Solved]: What if a formal grammar cannot be terminated?
Problem Detail: I’m currently in a class on Computability and we just finished looking at formal grammars before moving onto finite automata. We were given an several examples of a formal grammar, and one stuck out in particular: V: { S, Read More …
[Solved]: How to write CFG for languages
Problem Detail: How do you write the CFG for the following language: {ax by c ax+y} Is there some formula or rules I need to follow? An explanation will be so appreciated. What I tried is: First I broke ax+y into Read More …
[Solved]: Research on evaluating the performance of cache-obliviousness in practice
Problem Detail: Cache-oblivious algorithms and data structures are a rather new thing, introduced by Frigo et al. in Cache-oblivious algorithms, 1999. Prokop’s thesis from the same year introduces the early ideas as well. The paper by Frigo et al. present some Read More …
[Solved]: How to show that f(x) is primitive recursive?
Problem Detail: Let $$f(x)=begin{cases} x quad text{if Goldbach’s conjecture is true } 0 quad text{otherwise}end{cases}$$ Show that f(x) is primitive recursive. I know a primitive recursive function is obtained by composition or recursion, but I don’t know what should I Read More …
[Solved]: Prove finding a near clique is NP-complete
Problem Detail: An undirected graph is a near clique if adding an additional edge would make it a clique. Formally, a graph $G = (V,E)$ contains a near clique of size $k$ where $k$ is a positive integer in $G$ if Read More …
[Solved]: Regular expressions and semi-linear sets
Problem Detail: In proving Parikh’s Theorem, my Theory of Computer Science textbook defines a linear set as: $u_0 + langle u_1, dots, u_m rangle = {u_0 + a_1u_1 + dots + a_mu_m mid a_1, dots, a_m in mathbb{N}}$ where $u_i$ are Read More …