instruction
stringlengths
35
29.1k
I want use DFA to describe a sequence of movements in a 2D-space (language will be the path accepted by automaton in a particular case). That is a typical modeling problem: how can I encode a sequence of 2D movements in a DFA? Infact, walking through DFA or NFA seems a process analogous to walk through point of a maps...
My question is on data rate and baud rate. data rate = baud rate * n The question is, can you keep on increasing the data rate by increasing baud rate or number of bits. I believe it can be increased by increasing the baud rate but what about the latter part?
Thanks to anon for contributing this wording: Every permutation $\pi:\{1,\cdots,n\}\to\{1,\cdots,n\}$ induces an $n\times n$ array $A(\pi)$ of the absolute differences, whose $ij$ entry is $|\pi(i)-\pi(j)|$. I want an algorithm which takes as input a (possibly only-partially-filled in) $n\times n$ array $D$, and output...
There is popular problem: Given that integers are read from a data stream, find the median of elements read so far in an efficient way. One of possible solutions: Use max-heap for left heap (i.e. for elts lower than median) and min-heap for right heap (i.e. for elts higher than median). While receiving each new int...
Given a matrix $\mathsf{a}$ of size $K\times N$, what is the best complexity of finding the minimum value? Here is a pseudo code: function find_min(a) imin, jmin = 1, 1 for k = 1 to K for n = 1 to N if a[k, n] < a[imin, jmin] imin = k jmin = n return i...
I am presented with a comparison network. How can I determine if the comparison network is a sorting network? In the image below there is an example of a selection sort and insertion sort network. The intent is to have a comparison network and sort numeric values. If I test 2^n values in this case 2^8. This is a lot of...
I was going through the fundamentals of tree structure and the definition for ancestor is as follows: A node u is an ancestor of v if there is a path from u to v. Consider the node 11. Is node 2 (not the root, the other one on the left) an ancestor of node 11? It is strictly not a grandparent of 11, however, there d...
You want to visit n cities: $0 → 1 → 2 → · · · → n$. For traveling between city $i$ and $i + 1$ $(0 ≤ i < n) $ you need to choose between two modes of transportation: train or plane. You are starting at the train station of city $0$ and want to end up at the airport of city $n$. The cost of transferring between the t...
My professor have asked me strange question , about converting from Context free grammar to chomsky normal form , Can we remove unit productions first from CFG if possible , before removing null productions , does it effect the Chomsky normal form ?
Levenshtein-Distance edit distance between lists is a well studied problem. But I can't find much on possible improvements if it is known that no element does occurs more than once in each list. Let's also assume that the elements are comparable/sortable (but the lists to compare are not sorted to begin with). In ...
I've recently heard an interesting analogy which states that Turing's proof of the undecidability of the halting problem is very similar to Russell's barber paradox. So I got to wonder: mathematicians did eventually manage to make set theory consistent by transitioning from Cantor's naive formulation of the field to a ...
I am aware that deciding the existence of decomposition of a cubic graph into edge-disjoint claws is polynomial time solvable. Since a cubic graph has a decomposition into edge-disjoint claws if and only if it is bipartite. What is the complexity of deciding the existence of decomposition of a cubic graph into vertex ...
What I am doing: I've been reading there about front-side busses (FSB) and their cycles per second (MHz) vs. bandwidth (Millions of Transactions per second or MT/s). What I've understood: FSB's MHz is the actual speed it does per cycle, however, the speed per second depends on how many cycles it does per second What I ...
I saw in an answer to this post that it is possible to construct 3-sat clauses with extra variables such that the number of positive and negative literals for each variable are equal. Does anyone know of a construction for 2-sat instances to accomplish this or know it to be impossible? I have been trying, but all I h...
I’m a sucker for mathematical elegance and rigour, and now am looking for such literature on algorithms and algorithm analysis. Now, it doesn’t matter much to me what algorithms are covered, but very much how they are presented and treated.¹ I most value a very clear and precise language which defines all used notions ...
The language A, that is all DTMS that run forever on input. Would this not just be the HALT problem? Therefore no reduction or proof is necessary, other then stating that? ANSWER FOUND: I think i have it, if it was Turing Recognizable, then it would be possible to determine when HALT should reject and therefore HALT w...
I'm comfortable with showing NP-completeness of a decision problem: just take some problem that is known to be hard and reduce it to your new problem. This establishes NP-hardness of the new problem. But we can also have NP-hard search problems. For example, it is claimed in the introduction of this paper, that finding...
I have a context-free language $L(G)$. I'm reading in a book that $L(G') = L(G) - \{{\epsilon}\}$ is context-sensitive but I cannot find a proof or confirmation of this fact; moreover, in other texts the production $S\to\epsilon$ is allowed (as long $S$ isn't on the right hand side of any production) I'm quite confused...
Application: We intend to factor an integer $N$ using a variation of the rational sieve. This involves constructing a congruence of squares modulo $N$ from a set of linear relations $$x - N = y$$ where $x$,$y$ are $B$-smooth. The standard method to obtain such relations is to traverse $f(x) = x - N$ using a highly-opti...
In some papers, they proposed a model in which the joint posterior probability was modeled as[1]: $$ P(Y|\textbf{X},G) = \frac{P(\textbf{X},G|Y)P(Y)}{P(X,G)} \propto P(\textbf{X}|Y) \cdot P(Y|G)$$ where $\textbf{X}$ is attribute vectors set and $Y$ is the labels of all the edges in the network. I know the meaning of t...
Let languages $A, B$ be defined as $$\begin{align} A &= \{\langle M\rangle\mid M(\langle M\rangle)=reject\}\\ B &= \{\langle M\rangle\mid M(\langle M\rangle)=accept\} \end{align}$$ In other words, $A$ is the set of descriptions of TMs which reject their own descriptions and $B$ is defined similarly. The languages $A$ ...
The width (number of registers) and depth (number of hash functions) of a Count-Min sketch determine the accuracy of counts retrieved. I've found two different methods for calculating the width ($w$) and depth ($d$). First Method The clearest example I've found is from a 2011 paper by the original Count-Min authors: S...
Is there anything that hints at the possibility of a (modern) continuous-value computer, since modern computers are based on discrete arithmetic? I guess the old analog computers were of this continuous-value type, but is there any modern development? Do you know something about the issues regarding computability on su...
$SubsetGCD$ is described by the following: instance: A set of positive integers $S$ and an integer $k$ question: does there exist a subset $S'$ of $S$ of size $k$ such that $GCD(S') = GCD(S)$ Prove that $SubsetGCD$ is np complete. The hint for the problem is to reduce $VertexCover$ to $SubsetGCD$ I know what I'm supp...
Could you please resolve a confusion with Schaefer's theorem for me? Namely, why does it not imply many problems in P are NP-complete? For example, primality testing surely cannot be reduced to one of the six classes in the theorem, so why does that not imply it's NP-complete?
λ-calculus terms can be informally/intuitively categorized, such as: (λ f x . (f (f (f x))))) is a church natural (3) (λ a b . a) is a church boolean (true) (λ c n . (c 1 (c 2 (c 3 n)))) is a church list ([1,2,3]) (λ s z . (s (λ s z . (s (λ s z . (s (λ s z . z))))))) is a peano natural (3) That is, while the untyped ...
The tree traversal methods explained in this Wikipedia article are pre-order, post-order and in-order. Are these methods limited to binary trees? The algorithm seems to be defined in terms of left and right child. If it can be used for n-ary trees, how? An n-ary tree has 1 parent and n children at any given node. Where...
On the Wikipedia page for quantum algorithm I read that [a]ll problems which can be solved on a quantum computer can be solved on a classical computer. In particular, problems which are undecidable using classical computers remain undecidable using quantum computers. I expected that the fundamental changes that a qua...
Handwriting recognition is an important but very complicated domain of Computer Sciences. Computers nowadays do a quite fair job even if there is room for improvement in the future. I am wondering if the result is language-dependant: 1) Are there languages that are more easily analyzed by handwriting recognition progra...
I observe a scene with two cameras, c1 and c2, that produce two images i1 and i2, respectively. What I now want is to bring i1 and i2 into alignment, that is I want to know where pixel (x,y) in i1 is in i2. This "alignment-matrix" should be valid in general, that is not only for i1 and i2, but also for further images o...
Does a sufficiently complex neural network guarantee to find the optimal solution, given an infinite amount of data and the back propagation technique for training? In other words, given an infinite amount of training data, can neural network get out of local minima and approaches optimal state? The question is purely...
I have a thermal camera that I would like to overlay automatically to the output of a RGBD camera (e.g., Kinect). I can retrieve the intrinsic parameters of the thermal camera by using a special board I built, that allows the thermal camera to give as output a series of points similar to the ones obtained with a visi...
Given languages $A$ and $B$, let's say that their concatenation $AB$ is unambiguous if for all words $w \in AB$, there is exactly one decomposition $w = ab$ with $a \in A$ and $b \in B$, and ambiguous otherwise. (I don't know if there's an established term for this property—hard thing to search for!) As a trivial examp...
I am looking at this paper : http://arxiv.org/pdf/1411.3419v1.pdf But somehow I am not being able to fish out a method to calculate this quantity called the "block-sensitivity". Can someone kindly provide some discussion/examples or such? I am wondering if there is a way to talk of "block sensitivity" of any functi...
Given a list of real numbers. Is it possible to find the variance with no more than 1 iteration with constant space complexity?
I learned that recursive Fibonacci is $O(2^N)$. However, when I implement it and print out the recursive calls that were made, I only get 15 calls for N=5. What I am missing? Should it not be 32 or near abouts? It's like less then half! $COUNT = 0 def fibonacci( n ) $COUNT +=1 return n if ( 0..1 ).include? n ...
I observe a scene with two cameras, c1 and c2, that produce two images i1 and i2, respectively. What I ultimately want to do is to use information of image i1 and image2 simultaneously, e.g., for object detection. As far as I understand it, I would not be required to find the intrinsic parameters of c1 and c2, also I d...
Is it possible to get E from F? I suppose that can't work, because then I could calculate the the extrinsic (and maybe also intrinsic?) parameters of the cameras without a calibration object of known size etc. like so: Pick (8) corresponding points in images i1 and i2 Calculate F with the eight-point-algorithm Calcula...
Let's say I have a set of edges which makes the contour, however there are too many of them and some are too long. I have to remove edges, and shorten them to make contour. I cannot add new edges! I am looking at least for the name of the algorithm to further look how this problem is solved. Here is the example (please...
Consider the following game: One day a castle is attacked at sunrise (by surprise) by n soldiers. Each soldier carries a canon and a rifle. The castle has strength s. On the first day each soldier shoots his canon at the castle costing the castle n strength points (i.e. the castle ends the first day with s=s-n strengt...
The halting problem states there is no algorithm that will determine if a given program halts. As a consequence, there should be programs about which we can not tell whether they terminate or not. What are the simplest (smallest) known examples of such programs?
From wikipedia: For some approximation algorithms it is possible to prove certain properties about the approximation of the optimum result. For example, a $ρ$-approximation algorithm $A$ is defined to be an algorithm for which it has been proven that the value/cost, $f(x)$, of the approximate solution $A(x)$ to an ins...
There's a way to perform fuzzy parsing (accepts strings even with typos to a certain edit distance), with a DFA and a run-time constructed Levenshtein Automata of the input word. Can something similar be done with an Earley parser? I'm finding it hard to understand the algorithm, let alone answer this question.
Consider the problem of finding a maximum cardinality bipartite matching under the additional condition that some set $S$ of nodes (all lying on the same side of the bipartition) must be matched. Can this problem be reduced to (ordinary) bipartite matching? Bipartite matching can be solved in $O(m \sqrt{n})$ by Hopcro...
I am currently working on problem that I think could be expressed as an integer lattice problem, and hoping to find some guidance on this forum. Given $u \in \mathbb{R}^n$ and a bounded integer lattice $L = \mathbb{Z}^n \cap [-M,M]^n$, I would like to find an integer vector $v \in L$ such that the angle between $u$ and...
Today I heard of BNF which is a language for languages. Also heard that it specifies the entire syntax of C in four pages. So I thought of checking it out. After reading through this page, I got a fair idea about how to read the syntax. But I don't understand what the first two lines mean: %token int_const char_const f...
This may be a basic question, but I'm hoping someone can settle this nagging doubt I'm having. I'm reading up on FPT complexity using a book by Downey and Fellows. It has some introductory examples which detail complexity in terms of $|G|$, which seems to denote $|V|$ as mentioned here. The sections containing those ex...
I am having a bit of brain fail and I can't remeber the name of the following problem (so I can find some literature around it...). Given a sequence of values, sort it in a way that equal elements are compacted in runs (contiguous subsequences of identical elements). For instance: $$ \{1, 2, 4, 2, 1, 3\} \rightarrow ...
After reading of the google deepmind achievements on Atari's games, I am trying to understand the q-learning and q-networks, but I am little bit confused. The confusion arise in the concept of the discount factor. Brief summary of what I understand. A deep convolutional neural network is used to estimate the value of t...
In my text book it is mentioned that: $\emptyset^*=\{\epsilon\}$ where $\emptyset$ is an empty language. However, we know that $L \cdot \emptyset = \emptyset$, where $L$ is any Language. I am not able to intuitively grasp this concept because the Kleene star operation points towards the fact that $\emptyset^*=\emptyset...
Lemma 34.1 Let $Q$ be an abstract decision problem on an instance set $I$, and let $e_1$ and $e_2$ be polynomially related encodings on $I$. Then, $e_1(Q)\in \mathrm{P}$ if and only if $e_2(Q)\in\mathrm{P}$. Proof: We need only prove the forward direction, since the backward direction is symmetric. Suppose, therefor...
I'm reading Tracy Kidder's "The Soul of a New Machine" where a team at Data General design a new machine (codenamed "Eagle", later named MV/8000). It is 32-bit extension of a previous architecture (the 16-bit Eclipse). One of the revolving themes seems to be, that they don't want to create a machine with a mode bit and...
I'm looking into various SAT-solvers and trying to understand how they work and why they are designed in certain ways. (But I'm not in a university at the moment and I do not know anyone who is a professor. So I'm posting here hoping that someone can help me out. I'd really appreciate.) In Chaff, BCP (Boolean Constrain...
I was wondering as what are the specific conditions which make the A* algorithm - optimal in terms of the node expansion over the other Unidirectional algorithms: When the same heuristic information is given to all the algorithms.
Consider a basic integer program such as: $$\begin{align} \min_x & \quad c^Tx \\ \text{s.t.} & \quad Ax \leq b \\ &\quad x_i \in \{-100,\ldots,100\} \end{align} $$ where $x \in \mathbb{Z}^n, A \in \mathbb{R}^{m \times n}$ and $b \in \mathbb{R^m}$. Say that I have a feasible point $y \in \mathbb{Z}^n \cap [-100,100]^n$...
I'm dealing with this recurrence equation: $\qquad\displaystyle T(m, n) = T(m/2, n/2) + T(m, n/2) + O(1)$. Any idea how to solve this? I've looked in to few advanced resources but the literature on two dimensional recurrence equation seems to be very thin.
It is quite easy to show that the following two functions are primitive recursive and thus also $\mu$-recursive: $$ifthen(n,a,b) = \begin{cases}a & n > 0 \\ b & else\end{cases} $$ $$ eq(x,y) = \begin{cases} 1 & x = y \\ 0 & else\end{cases} $$ Now, given a $\mu$-recusive function $f$ which is not total, i.e. whose doma...
For Earliest Deadline First, I have read that if utilization is less or equal to 1, the task set is schedulable under EDF. But does this criteria expresses the optimality for EDF? If not, how can we express optimality of EDF? So if I get asked is EDF optimal, can I get away with the following sentence? EDF is able to e...
I am stuck with constructing an DFA that has at most in it. The question I am stuck with is: Design an DFA that accepts all strings over {0, 1} that contain at most two 00’s and at most three 11’s as a substring. An answer in a form of a graph would be perfect but if someone can explain in plain words, I will apprec...
Lets say we have a binary tree $T$ and we want to insert key $k$. Now, assuming $k\not\in T$, how do we find the symmetric predecessor/successor of $k$? Does this relate to (pre/in/post)-order traversals in some way?
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. The question asks: For each function $f(n)$ and time $t$ in the following table, deter...
I need to draw a machine's states that accepts (writes a 1) when it reads a string of x's that is followed by the same number of y's and would reject (writes a 0) for anything else. It has to work for all possible input tapes. For example, it would accept xxxyyy but would reject xxyyy and xx. I cannot figure out how to...
I know that the clique problem is NP-complete. However, what if we change the problem a little bit? For example, Given a graph $G(V,E)$, an integer $k$ and a subset $S$ of $m$ vertices, we are given a decision problem to find a clique with size $k$ contained within $S$. A real world example would be something like a s...
In my theory of computation class last Spring my professor said in passing that a programming language cannot be both fully recursive and polymorphic. I didn't think much of it till now? What does it mean to be "fully" polymorphic and why does that mean you a language can't be "fully" recursive?
What is that fastest algorithm that can calculate a lot of digits of a decimal root? For example: 10,000 digits of the 3.56th root of 60.1?
Given a graph $G$ directed with n nodes and m edges, if an algorithm solves a problem $X$ on $G$ with a complexity $O(n^2)$, while an other algorithm solves same problem $X$ on $G$ but with complexity $O(m)$, what is the most efficient ?
I have some modified automata and the task is to give the type of Chomsky hierarchy to it. All task is between type 3 and 0 noninclusive. For regular languages there are lot of tools and I can check it without problems, Turing Machine equivalent is also easy task, and there will be no such examples. Now the question: i...
In the book Algorithms, 4th Edition by Robert Sedgewick and Kevin Wayne, when they are analyzing quicksort (page 294), they present the sequence of transformations: $$\begin{gather*} C_N = N + 1 + (C_0 + C_1 + \dots + C_{N-2} + C_{N-1})/N + (C_{N-1} + C_{N-2} + \dots + C_0)/N\\ NC_N = N(N+1) + 2(C_0 + C_1 + \dots + C_...
I'm trying to come up with a reduction for a problem whose description is more or less identical to the first problem given here. Here's a condensed version of the problem: You're given a collection of refrigerator magnet letters that may contain duplicates. You have a limited vocabulary of words made of combinations o...
Please correct me on any terminology. For some reason I'm a bit confused. $\Sigma = \{\epsilon, 0, 1\}$ This means my alphabet, $\Sigma$, contains three symbols ($\epsilon, 0, 1$). $\Sigma^*$ is the language over $\Sigma$, and it equals $\{\epsilon, 0, 1, 01, 10\}$. My regular expression for $\Sigma^*$: $\epsilon+0+1+(...
Find the least number of comparisons needed to sort (order) five elements and devise an algorithm that sorts these elements using this number of comparisons. Solution: There are 5! = 120 possible outcomes. Therefore a binary tree for the sorting procedure will have at least 7 levels. Indeed, $2^h$ ≥ 120 implies $h...
Let's say I have $\Sigma = \{0\}$. Can a language $L$ be as large as $\Sigma^*$? So $L = \Sigma^*$. Can a language $L$ be as small as just $\{0\}$? A subset of $\Sigma^*$. Can multiple languages, $L_1, L_2$, come from the same $\Sigma$, i.e. be subsets of the same $\Sigma^*$?
If I had productions like so... $S \rightarrow A1B$ $A \rightarrow \epsilon$ $A \rightarrow 0$ $B \rightarrow \epsilon$ $B \rightarrow 1$ If I only want strings $\{\epsilon1\epsilon, 011\}$, am I allowed to choose when both $A$ and $B$ become $\epsilon$? Or will I get resulting strings such as $\epsilon11$ and $01\epsi...
I found the following assertion in a neural networks FAQ: Radial networks typically have only one hidden layer, but it can be useful to include a linear layer for dimensionality reduction or oblique rotation before the RBF layer But I could not find any "formal" reference (published works) showing it. I found som...
I am looking for an algorithm that, given an undirected, planar graph $G = (V,E)$ with node weights, meets the following conditions: Creates balanced (within some margin) $k$ partitions of $V$ according to node weight. All partitions have to be connected. It cannot minimize communication volume, or edge cuts. My grap...
How do I go about finding a language recognized by the following automaton? And is it possible to find a corresponding regular expression? I've read some posts about the same issue here on CS.SE but none of the approaches seem to give me a solution. EDIT: I've just learned Arden's theorem and the method of solving thi...
The language $L = \{0^{2n} \space |\space n \ge 0 \}$ is obviously regular – for example, it matches the regular expression $(00)^*$. But the following pumping lemma argument seems to show it's not regular. What's gone wrong? I've found a way of splitting an input $s$ as $xyz$ satisfying the requirements of the pumping...
I'm developing a model in C, and I need to run a couple of simulations (lengthy, and heavy ones). I seem to have a cluster at my disposal, but I'm not very familiar with the concept. I understand that there are different "nodes" ? My program is not designed to take advantage of this individually - it can't event take a...
I have a collection of vectors $v_1,v_2\in [0,1]^n$ and I want to find similar pairs quickly. For similarity, I want to use the Euclidean distance metric $L: [0,1]^n \times [0,1]^n \longrightarrow R$. $n$ will be around $200$. I've implemented Locality Similar Hashing (LSH) for word based documents, and I'm curious if ...
The Complexity Zoo defines $LIN$ to be the class of decision problems solvable by a deterministic Turing machine in linear time. $$LIN \subseteq P$$ Since HORN-SAT is solvable in $O(n)$ (as indicated in Linear-time algorithms for testing the satisfiability of propositional horn formulae (1984)) New algorithms for dec...
I am a green-hand in calculating the time complexity. Given a calculation as follows: \begin{equation} \mathbf{x}=\mathbf{A^T}(\mathbf{AA^T}+\lambda\mathbf{I}_n)^{-1}\mathbf{b} \end{equation} where $\mathbf{A}\in R^{n\times p}$, $\mathbf{I}_n\in R^{n\times n}$, $\mathbf{b}\in R^{n}$ and $\lambda\in R$. Could some one k...
I have the next problem, and I was wondering whether it exists a way to solve it without having to iterate around all the array in the worst case. I have a sorted array of pairwise distinct integers, say $[1,2,4,5,7,8]$ I need to know if there is a gap of at least two between two consecutive integers, i.e., if there ar...
Let $\mathrm{L} \in \mathrm{NTIME}(n^3)$. Since $\mathrm{NTIME}(n^3) \subseteq \mathrm{NP}$, we have that $\mathrm{L} \le_p \mathrm{3SAT}$. However, $\mathrm{3SAT} \in \mathrm{NTIME}(n)$. Hence, $\mathrm{L} \in \mathrm{NTIME}(n)$. Thus, $\mathrm{NTIME}(n^3)\subseteq \mathrm{NTIME}(n)$ which implies the non-deterministi...
Here's a problem I need to solve that's clearly related to the standard bin-packing problem, but I'm not sure how to approach it. Suppose you have some finite set of bins $B$, and each $b_i \in B$ has some integer capacity $\mathit{cap}(b_i)$. You also have some set of items $L$ where each item $l_j \in L$ has some int...
Is there a known/existing algorithm for taking a 2D canvas covered in arbitrarily/randomly distributed points and dividing it entirely into a set of non-overlapping polygons? An example of the kind of result I'm looking for:
I'm building a non linear svm for images to solve a classification problem with domain {0, 1} and I'm currently doing featurization. What I want to do is create 3 features for each pixel representing the rgb value. However, my input images have different dimensions meaning that they are of different widths and heights....
I have an intuitive concept of systems that grows in complexity steadily as it computes. I can think in some examples: Nature. Given the physical laws, some initial conditions (say, the Earth planet at the beginning of life) and enough time, the system eventually evolves in complexity, all the way from dinosaurs fight...
From Introduction to Algorithms by Thomas H. Cormen, Charles E. Leiserson, Ronald L. Rivest, and Clifford Stein Theorem 3.1 For any two functions $f(n)$ and $g(n)$, we have $f(n) = \Theta(g(n))$ if and only if $f(n) = O(g(n))$ and $f(n) = \Omega(g(n))$ The worst case run time complexity of insertion sort is $O(n^2)$. H...
I am having some trouble understanding why people say that contrary to what happens with AVL trees, there is a bound on the number of rotations occurring in an insertion with a Red Black Tree. From what I've gathered, there are several special cases to take into consideration in the fixUp algorithm posterior to the sta...
I always wondered what the algorithm might be to generate graphs such as those found on Sedgewick's algorithms books (consider the picture on the left): Could any one point me to the name (or algorithm) that creates such a graph over a 2D region? I am not interested in how to draw it or display it (or in any library)....
I am trying to find the algorithm for the 0-1 goal programming problem. Actually I don't have any recent references for explicit algorithms, all the recent articles are about the modelling and not about the solution and algorithms (the solution is found using the commercial software like LINGO or CPLEX). Now I am think...
Given three languages $L_1, L_2, L_3$ with $L_1$ and $L_3$ being semi-decidable and $L_1 \subseteq L_2, L_2 \subseteq L_3$. Can I deduce from these properties, that $L_2$ is also semi-decidable and how would I proof this? Intuitionally it seems obvious that $L_2$ is also semi-decidable, but I didn't find a way to prove...
Automatas are turing-complete grid-based systems with progression rules on which we can encode arbitrarily complex structures. For example, this is a "glider gun" on Conway's Game of Life: Due to turing-completeness, with enough efforts, one could encode fully-featured structures, such as machines that claimed territo...
I'm having a problem understanding this conversion. Let's say we have a CFL like this: $ { a^nb^m : n > m } $ A final state acceptance PDA for this language would push $A$ symbols in the stack for every 'a' input, and pop them for every 'b' input. If the stack has no more $A$s while we still have 'b' inputs to process,...
Suppose I have a simple dependent type theory with bottom, unit, sums, dependent pairs, dependent functions, natural numbers and homogeneous identity with J-elimination. Is there a way to prove $(0 = 1) \rightarrow \bot$? Or do I need K for that?
From Xiong, Hui, Shashi Shekhar, Pang-Ning Tan, and Vipin Kumar. “TAPER: A Two-Step Approach for All-Strong-Pairs Correlation Query in Large Databases.” Knowledge and Data Engineering, IEEE Transactions on 18, no. 4 (2006): 493–508. : Support measures the fraction of transactions that contain a particular subset of...
I am a little confused about the differences between Approximation Bayesian Computation (ABC) and Monte Carlo Methods (MCM). Citing from wikipedia: Approximate Bayesian computation (ABC) constitutes a class of computational methods rooted in Bayesian statistics. In all model-based statistical inference, the likelihood...
I've been self-studying algorithms and am currently working on one of the starred exercises from CLRS: Exercise 6.4-5 Show that when all elements are distinct, the best-case running time of heapsort is $\Omega(n\text{log}(n))$. I've been thinking over this for about a day or so, and so far I've tried working with findi...
I'm working on implementing some exact real arithmetic operations for fun. I've got the rough outline of how I want to do things as well and have figured out how to write most of the important algorithms (though I have not properly implemented them just yet). Going against the "pre-mature optimization is bad, m'kay" ph...
Assume the CPU has 64 data lines. Then Z reading cycles will be needed to load an array of 12 double-precision floating-point numbers, each number coded in eight bytes, from the main memory into the CPU. Z = ? So I'm looking at some of the past exam questions to prepare for my exams next year and this question (above) ...