Problem Detail: In trying to understand the relationships between Huffman Coding, Arithmetic Coding, and Range Coding, I began to think of the shortcomings of fuffman coding to be related to the problem of fractional bit-packing. That is, suppose you have 240 Read More …
Author: ignougroup
[Solved]: What is the difference between “definition” and “inductive” in Coq?
Problem Detail: In Coq, you can use two different kinds of keywords to do definitions–Inductive and Definition. I do not understand the difference between an inductive and a definition, or when it is appropriate to use one instead of the other. Read More …
[Solved]: Exercise on Divide&Conquer’s technique
Problem Detail: I need help on this exercise: You are given an array of n elements, and you notice that some of the elements are duplicates; that is, they appear more than once in the array. Show how to remove all Read More …
[Solved]: Where in the Chomsky Hierarchy are Regular Expressions as a language?
Problem Detail: I’m referring to regular expressions as language: begin{equation*} Sigma = { “a”, “b”, “(“, “)”, “*”, … } end{equation*} and begin{equation*} L = Sigma^* text{, which form a legal regular expression} end{equation*} I am not referring to their computational Read More …
[Solved]: Number of digits in a binary product
Problem Detail: Assume i have 2 numbers in binary form (or, more precisely, assume to know the number of their digits, DF1, DF2): 101010101001010101010101010111111111111111111111010101 10101111111111111111010101 Is there a formula for the exact number of binary digits (DP) of the product? DP Read More …
[Solved]: Does NP-completeness require to find the solution?
Problem Detail: In the paper “Computing Equilibria:A Computational Complexity Perspective” by Tim Roughgarden, they consider the problem: Problem 2.1 (Clique). Given a graph $G = (V, E)$ and an integer $k$: if there is a set $K ⊆ V$ with $|K| Read More …
[Solved]: Cost of partitioning in quicksort
Problem Detail: I’m reading “Algorithms Fourth Edition” by Sedgewick & Wayne and am wondering if I have spotted an error in the book or if I just can’t wrap my head around something so simple. When talking about the complexity of Read More …
[Solved]: Is it decidable whether a Turing machine will ever leave the start state on any input?
Problem Detail: Is $L={ M | Mtext{ leaves the start state on every input}}$ decidable? I have an intuition that the following language is undecidable, since the complement $L^C$ seems to not be recursively enumerable. Some TM might remain on the Read More …
[Solved]: Multiplication in $O(ncdot log n)$
Problem Detail: I was looking in here, and I noticed the best runtime for multiplication of two $n$-bits numbers is $O(ncdot log n cdot 2^{O(log^* n)}$, but I can easily notice an algorithm that runs in $O(ncdot log n)$. After all, Read More …
[Solved]: How can I prepare for CS in university
Problem Detail: How can I prepare for an introductory CS college course? I am currently in Grade 12 and next year I will be studying Computer Science at a university in South Africa (syllabus is here). However CS has a very Read More …