id
int64
1
141k
title
stringlengths
15
150
body
stringlengths
45
28.5k
tags
stringlengths
1
102
label
int64
1
1
text
stringlengths
128
28.6k
source
stringclasses
1 value
49,250
Determining whether a digital circuit is optimal
<p>Are there any techniques that can be used to determine whether a digital logic circuit is optimal, or if it has extraneous operations that don't contribute to the output?</p>&#xA;&#xA;<p>I'm especially curious in the case where the circuit is defined in terms of XOR and AND gates.</p>&#xA;&#xA;<p>I know I could make...
optimization digital circuits
1
Determining whether a digital circuit is optimal -- (optimization digital circuits) <p>Are there any techniques that can be used to determine whether a digital logic circuit is optimal, or if it has extraneous operations that don't contribute to the output?</p>&#xA;&#xA;<p>I'm especially curious in the case where the c...
habedi/stack-exchange-dataset
49,266
Finding a minimal cover of a subset of a finite cartesian product by cartesian products
<p>Given a subset of a cartesian product $I \times J$ of two finite sets, I wish to find a minimal cover of it by sets which are cartesian products themselves.</p>&#xA;&#xA;<p>For example, given a product between $I=\{A,B,C\}$ and $J=\{1,2,3\}$, I may observe the subset $\{(A,2), (B,3), (B,2)\}$ and try to cover it wit...
algorithms set cover
1
Finding a minimal cover of a subset of a finite cartesian product by cartesian products -- (algorithms set cover) <p>Given a subset of a cartesian product $I \times J$ of two finite sets, I wish to find a minimal cover of it by sets which are cartesian products themselves.</p>&#xA;&#xA;<p>For example, given a product b...
habedi/stack-exchange-dataset
49,271
Is the program in secondary memory can be a process?
<p>Let us consider the following scenario,</p>&#xA;&#xA;<p>The cpu started executing a program, which is in secondary memory with n lines of code, so, it brings m ( &lt; n ) lines of code in to main memory and started executing.</p>&#xA;&#xA;<p>We can call the m lines of code, which are in main memory as process.</p>&...
terminology process scheduling
1
Is the program in secondary memory can be a process? -- (terminology process scheduling) <p>Let us consider the following scenario,</p>&#xA;&#xA;<p>The cpu started executing a program, which is in secondary memory with n lines of code, so, it brings m ( &lt; n ) lines of code in to main memory and started executing.</...
habedi/stack-exchange-dataset
49,281
Halting problem without input?
<p>I'm only a layman therefore only discuss stuff naïvely.</p>&#xA;&#xA;<p>I read some introductory articles about halting problems with a scenario that if there were such a decider accessible to us, we should be able to solve some unsolved mathematical problems. We could write some brute-force programs to check Goldba...
computability undecidability halting problem
1
Halting problem without input? -- (computability undecidability halting problem) <p>I'm only a layman therefore only discuss stuff naïvely.</p>&#xA;&#xA;<p>I read some introductory articles about halting problems with a scenario that if there were such a decider accessible to us, we should be able to solve some unsolve...
habedi/stack-exchange-dataset
49,286
Consequence of NP=coNP to some hierarchy problems
<p>If $NP=coNP$ does it hold that $P/Poly=PH/Poly$ and/or $NP\subseteq P/Poly$ and/or $VNP=VP$?</p>&#xA;&#xA;<p>What can we legitimately say if $NP=coNP$?</p>&#xA;
complexity theory complexity classes
1
Consequence of NP=coNP to some hierarchy problems -- (complexity theory complexity classes) <p>If $NP=coNP$ does it hold that $P/Poly=PH/Poly$ and/or $NP\subseteq P/Poly$ and/or $VNP=VP$?</p>&#xA;&#xA;<p>What can we legitimately say if $NP=coNP$?</p>&#xA;
habedi/stack-exchange-dataset
49,288
3-COL with a restriction on a number of vertices colored with a particular color
<p>If I modify a 3-COL problem (with colors A, B, C) in a way that I now demand that at most, say, 50 vertices may be colored with color A, does the problem still remain NP-complete?</p>&#xA;&#xA;<p>I've been thinking of a reduction from a standard 3-COL, but there is no way that I can solve a standard 3-colorability u...
complexity theory np complete
1
3-COL with a restriction on a number of vertices colored with a particular color -- (complexity theory np complete) <p>If I modify a 3-COL problem (with colors A, B, C) in a way that I now demand that at most, say, 50 vertices may be colored with color A, does the problem still remain NP-complete?</p>&#xA;&#xA;<p>I've ...
habedi/stack-exchange-dataset
49,295
Finding Minimum Weight Subgraph Spanning Tree
<p>Suppose we have a graph $G = (V, E, w:e\in E \to x \in \{0,1\})$. That is, a set of vertices, a set of edges and a weight function that assigns edges weights of 0 or 1.</p>&#xA;&#xA;<p>Suppose we also have a subset of vertices $S \subset V$ and that we want to find a minimum-weight tree that spans the vertices in $S...
algorithms graphs optimization trees
1
Finding Minimum Weight Subgraph Spanning Tree -- (algorithms graphs optimization trees) <p>Suppose we have a graph $G = (V, E, w:e\in E \to x \in \{0,1\})$. That is, a set of vertices, a set of edges and a weight function that assigns edges weights of 0 or 1.</p>&#xA;&#xA;<p>Suppose we also have a subset of vertices $S...
habedi/stack-exchange-dataset
49,309
Why there must be a relationship between user threads and kernel threads?
<p>The following is an excerpt from <a href="http://codex.cs.yale.edu/avi/os-book/OS9/" rel="nofollow noreferrer">OS concepts by galvin</a>.Here is the <a href="http://sist.sysu.edu.cn/%7Eisscwli/OSRef/Abraham%20Silberschatz-Operating%20System%20Concepts%20(9th,2012.12).pdf" rel="nofollow noreferrer">book</a>.</p>&#xA;...
operating systems concurrency threads
1
Why there must be a relationship between user threads and kernel threads? -- (operating systems concurrency threads) <p>The following is an excerpt from <a href="http://codex.cs.yale.edu/avi/os-book/OS9/" rel="nofollow noreferrer">OS concepts by galvin</a>.Here is the <a href="http://sist.sysu.edu.cn/%7Eisscwli/OSRef/A...
habedi/stack-exchange-dataset
49,311
How to remove empty strings a.k.a (lambda, epsilon) from a LR(0) grammar
<p>Say I have the following grammar:</p>&#xA;&#xA;<pre><code>E -&gt; TE'&#xA;E' -&gt; +TE'| -TE' | λ&#xA;T -&gt; (E) | id&#xA;</code></pre>&#xA;&#xA;<p>I need to build the finite state machine with the LR(0) items, </p>&#xA;&#xA;<p>But I know in order to do this I have to remove the λ. </p>&#xA;&#xA;<p>How to I acco...
finite automata formal grammars lr k
1
How to remove empty strings a.k.a (lambda, epsilon) from a LR(0) grammar -- (finite automata formal grammars lr k) <p>Say I have the following grammar:</p>&#xA;&#xA;<pre><code>E -&gt; TE'&#xA;E' -&gt; +TE'| -TE' | λ&#xA;T -&gt; (E) | id&#xA;</code></pre>&#xA;&#xA;<p>I need to build the finite state machine with the ...
habedi/stack-exchange-dataset
49,324
Solving recurrences by substitution method: why can I introduce new constants?
<p>I am solving an exercise from the book of Cormen et al. (<em>Introduction To Algorithms</em>). The task is:</p>&#xA;&#xA;<blockquote>&#xA; <p>Show that solution of $T(n) = T(\lceil n/2\rceil) + 1$ is $O(\lg n)$</p>&#xA;</blockquote>&#xA;&#xA;<p>So, by big-O definition I need to prove that, for some&nbsp;$c$,</p>&#x...
algorithm analysis proof techniques recurrence relation
1
Solving recurrences by substitution method: why can I introduce new constants? -- (algorithm analysis proof techniques recurrence relation) <p>I am solving an exercise from the book of Cormen et al. (<em>Introduction To Algorithms</em>). The task is:</p>&#xA;&#xA;<blockquote>&#xA; <p>Show that solution of $T(n) = T(\l...
habedi/stack-exchange-dataset
49,325
Why the extra state in this automaton?
<p>Why does the following DFA have (to have) the state $b_4$?</p>&#xA;&#xA;<p>Shouldn't states $b_1,b_2,b_3$ already cover "exactly two 1s"?&#xA;Wouldn't state $b_4$ mean "more than two 1s", even if it doesn't trigger an accept state?</p>&#xA;&#xA;<p><a href="https://i.stack.imgur.com/IwmOm.png" rel="nofollow noreferre...
automata finite automata
1
Why the extra state in this automaton? -- (automata finite automata) <p>Why does the following DFA have (to have) the state $b_4$?</p>&#xA;&#xA;<p>Shouldn't states $b_1,b_2,b_3$ already cover "exactly two 1s"?&#xA;Wouldn't state $b_4$ mean "more than two 1s", even if it doesn't trigger an accept state?</p>&#xA;&#xA;<p>...
habedi/stack-exchange-dataset
49,340
What is this DFA doing (carry bits)?
<p>I'm looking to understand how can one graph the following DFA given its mathematical definition.</p>&#xA;&#xA;<p>Take for example this (from [1], p. 107):</p>&#xA;&#xA;<ul>&#xA;<li><strong>Set of States</strong>: $Q = \{q_{\langle carry=0\rangle}, q_{\langle carry=1 \rangle}\}$</li>&#xA;<li><strong>Alphabet</strong>...
automata finite automata
1
What is this DFA doing (carry bits)? -- (automata finite automata) <p>I'm looking to understand how can one graph the following DFA given its mathematical definition.</p>&#xA;&#xA;<p>Take for example this (from [1], p. 107):</p>&#xA;&#xA;<ul>&#xA;<li><strong>Set of States</strong>: $Q = \{q_{\langle carry=0\rangle}, q_...
habedi/stack-exchange-dataset
49,342
If L is regular, show that even(L) is also regular
<p>I am stuck on the following question.</p>&#xA;&#xA;<blockquote>&#xA; <p>If $L$ is regular show that $\mathrm{even}(L)$ is also regular, where $\mathrm{even}(L) = \{ even(w) : w \in L \}$, $w$ is a string in $L$ and $\mathrm{even}(w)$ is the string obtained by extracting from $w$ the letters in even numbered positio...
formal languages regular languages closure properties
1
If L is regular, show that even(L) is also regular -- (formal languages regular languages closure properties) <p>I am stuck on the following question.</p>&#xA;&#xA;<blockquote>&#xA; <p>If $L$ is regular show that $\mathrm{even}(L)$ is also regular, where $\mathrm{even}(L) = \{ even(w) : w \in L \}$, $w$ is a string in...
habedi/stack-exchange-dataset
49,355
What is the difference between regular trees and phylogenetic trees in terms of graph theory?
<p>If I am not mistaken, a tree is any graph that does not contain cycles.</p>&#xA;<p>However, I am currently taking a bioinformatics course where we deal a lot with algorithms on phylogenetic trees. Usually you are given a phylogenetic tree with <span class="math-container">$n$</span> leafs, and then you run some algo...
algorithms algorithm analysis trees
1
What is the difference between regular trees and phylogenetic trees in terms of graph theory? -- (algorithms algorithm analysis trees) <p>If I am not mistaken, a tree is any graph that does not contain cycles.</p>&#xA;<p>However, I am currently taking a bioinformatics course where we deal a lot with algorithms on phylo...
habedi/stack-exchange-dataset
49,361
Intersection of Turing-recognizable language and regular language
<p>True or false:&#xA;An intersection of a Turing-recognizable and a regular language is always Turing-decidable.</p>&#xA;&#xA;<p>This was asked on a practice test and the answer is False. Why? I thought regular languages were a subset of decidable languages. So if you intersect regular and recognizable the result woul...
turing machines regular languages automata
1
Intersection of Turing-recognizable language and regular language -- (turing machines regular languages automata) <p>True or false:&#xA;An intersection of a Turing-recognizable and a regular language is always Turing-decidable.</p>&#xA;&#xA;<p>This was asked on a practice test and the answer is False. Why? I thought re...
habedi/stack-exchange-dataset
49,367
Fill in objects that pop out from background?
<p>I need some help with a program that will fill in objects that pop out from the background. For example I have this picture <a href="https://i.stack.imgur.com/fDaSw.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fDaSw.png" alt="enter image description here"></a>and would like to get an output lik...
algorithms image processing
1
Fill in objects that pop out from background? -- (algorithms image processing) <p>I need some help with a program that will fill in objects that pop out from the background. For example I have this picture <a href="https://i.stack.imgur.com/fDaSw.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fDaSw....
habedi/stack-exchange-dataset
49,378
Value returned by recursive function
<p>(pseudocode) <br></p>&#xA;&#xA;<pre><code>f(x,y,z) &#xA;{&#xA; if (x &lt; y) &#xA; {&#xA; return 1 + f(x + 1, y, z)&#xA; } &#xA; else if (y &lt; z) &#xA; {&#xA; return 2 + f(x, y + 1, z)&#xA; } &#xA; else &#xA; {&#xA; return z&#xA; }&#xA;}&#xA;</code></pre>&#xA;&#xA;<p...
recursion
1
Value returned by recursive function -- (recursion) <p>(pseudocode) <br></p>&#xA;&#xA;<pre><code>f(x,y,z) &#xA;{&#xA; if (x &lt; y) &#xA; {&#xA; return 1 + f(x + 1, y, z)&#xA; } &#xA; else if (y &lt; z) &#xA; {&#xA; return 2 + f(x, y + 1, z)&#xA; } &#xA; else &#xA; {&#xA; re...
habedi/stack-exchange-dataset
49,389
if $\delta(q, a) = q$ for all symbols $a$, show that $\delta^* (q, w) = q$ is true for all strings $w$
<blockquote>&#xA; <p>Let $A$ be a DFA and $q$ a particular state of $A$, such that&#xA; $\delta(q, a) = q$ for all input symbols $a$. Show by induction on the&#xA; length of input that for all strings $w$, $\delta^* (q, w) = q$.</p>&#xA;</blockquote>&#xA;&#xA;<p>I'm completely new to the subject. But this is what I ...
automata finite automata proof techniques
1
if $\delta(q, a) = q$ for all symbols $a$, show that $\delta^* (q, w) = q$ is true for all strings $w$ -- (automata finite automata proof techniques) <blockquote>&#xA; <p>Let $A$ be a DFA and $q$ a particular state of $A$, such that&#xA; $\delta(q, a) = q$ for all input symbols $a$. Show by induction on the&#xA; len...
habedi/stack-exchange-dataset
49,397
Help with building a NFA automaton
<p>$\Sigma=\{a,b\}$, $L=\{w\in \Sigma^* \Big| |w|=3n+5m, \ n,m\ge 0 \}$.<br>&#xA;I need to build NFA automaton for $L$....</p>&#xA;&#xA;<p>Now, I try it for hours but I don't have any idea how to solve it.<br>&#xA;I know that any $x\ge 8$ can be written as $3n+5m, \ n,m\ge 0 $&#xA;So, the automaton accepts any word the...
regular languages automata
1
Help with building a NFA automaton -- (regular languages automata) <p>$\Sigma=\{a,b\}$, $L=\{w\in \Sigma^* \Big| |w|=3n+5m, \ n,m\ge 0 \}$.<br>&#xA;I need to build NFA automaton for $L$....</p>&#xA;&#xA;<p>Now, I try it for hours but I don't have any idea how to solve it.<br>&#xA;I know that any $x\ge 8$ can be written...
habedi/stack-exchange-dataset
49,403
Reduction from deciders of the universal to deciders of the empty language
<p>$ALL_{TM} = \{\langle M\rangle | \; M$ is $TM$ and $L(M)=\Sigma^*\}$<br>&#xA;$E_{TM} = \{\langle M\rangle | \; M$ is $TM$ and $L(M)=\emptyset\}$ </p>&#xA;&#xA;<p>I can't find reduction of $ALL_{TM}$ to $E_{TM}$. But I can't proof that it does not exist. &#xA;Is there is such a reduction?</p>&#xA;
computability reductions
1
Reduction from deciders of the universal to deciders of the empty language -- (computability reductions) <p>$ALL_{TM} = \{\langle M\rangle | \; M$ is $TM$ and $L(M)=\Sigma^*\}$<br>&#xA;$E_{TM} = \{\langle M\rangle | \; M$ is $TM$ and $L(M)=\emptyset\}$ </p>&#xA;&#xA;<p>I can't find reduction of $ALL_{TM}$ to $E_{TM}...
habedi/stack-exchange-dataset
49,404
Secondary Storage in Von Neumann Achitecture
<p>For an assignment, I need to draw a diagram of Von Neumann architecture, and explain each part of it.</p>&#xA;&#xA;<p>All the diagrams and explanations I've seen have a distinct "Memory" block that holds both the code and the program data of running processes. What I can't find information on however is if this memo...
computer architecture
1
Secondary Storage in Von Neumann Achitecture -- (computer architecture) <p>For an assignment, I need to draw a diagram of Von Neumann architecture, and explain each part of it.</p>&#xA;&#xA;<p>All the diagrams and explanations I've seen have a distinct "Memory" block that holds both the code and the program data of run...
habedi/stack-exchange-dataset
49,413
Decidability of checking an antiderivative?
<p>Let's suppose I have two functions $F$ and $G$ and I'm interested in determining whether</p>&#xA;&#xA;<p>$$F(x) = \int G(x)dx.$$</p>&#xA;&#xA;<p>Let's suppose that my functions are composed of elementary functions (polynomials, exponentials, logs, and trigonometric functions), but not, say, Taylor series.</p>&#xA;&#...
computability undecidability mathematical analysis computer algebra
1
Decidability of checking an antiderivative? -- (computability undecidability mathematical analysis computer algebra) <p>Let's suppose I have two functions $F$ and $G$ and I'm interested in determining whether</p>&#xA;&#xA;<p>$$F(x) = \int G(x)dx.$$</p>&#xA;&#xA;<p>Let's suppose that my functions are composed of element...
habedi/stack-exchange-dataset
49,415
How to solve $T(n)=n+T(n/2)+T(n/4)+\cdots+T(n/2^k)$?
<p>How do I solve the recurrence relation $T(n)=n+T(n/2)+T(n/4)+\cdots+T(n/2^k)$, for constant $k$?</p>&#xA;&#xA;<p>I am told that the answer does not depend on $k$.</p>&#xA;
recurrence relation
1
How to solve $T(n)=n+T(n/2)+T(n/4)+\cdots+T(n/2^k)$? -- (recurrence relation) <p>How do I solve the recurrence relation $T(n)=n+T(n/2)+T(n/4)+\cdots+T(n/2^k)$, for constant $k$?</p>&#xA;&#xA;<p>I am told that the answer does not depend on $k$.</p>&#xA;
habedi/stack-exchange-dataset
49,427
Which pass do you look at for Radix Sort stability?
<p>I know this is a fairly poorly worded question, but I can't think of a better way to phrase it in the title. </p>&#xA;&#xA;<p>So in Radix Sort, you go digit by digit from least significant to most significant, and along the way you are swapping elements around. When considering the case where two digits are the same...
algorithms sorting radix sort
1
Which pass do you look at for Radix Sort stability? -- (algorithms sorting radix sort) <p>I know this is a fairly poorly worded question, but I can't think of a better way to phrase it in the title. </p>&#xA;&#xA;<p>So in Radix Sort, you go digit by digit from least significant to most significant, and along the way yo...
habedi/stack-exchange-dataset
49,432
In a $k$-way set associative cache,main memory block mapping in range?
<blockquote>&#xA;<p>In a <span class="math-container">$k$</span>-way set associative cache, the cache is divided into <span class="math-container">$v$</span> sets, each of which consists of <span class="math-container">$k$</span> lines. The lines of a set are placed in sequence one after another. The lines in set <span...
computer architecture operating systems memory management cpu cache
1
In a $k$-way set associative cache,main memory block mapping in range? -- (computer architecture operating systems memory management cpu cache) <blockquote>&#xA;<p>In a <span class="math-container">$k$</span>-way set associative cache, the cache is divided into <span class="math-container">$v$</span> sets, each of whic...
habedi/stack-exchange-dataset
49,435
Sorting array containing elements from $\{1,\ldots,k\}$ in place in $O(n\log k)$
<p>An array $a[1,\ldots,n] \subseteq \{1,\ldots, k\}$ is given, where $k &lt; \sqrt{n}$.<br>&#xA;Our goal is a project algorithm which sorts it in place and in time $O(n\log k)$.<br>&#xA;We assume that $k &lt; \sqrt{n}$ - otherwise $O(n\log k) = O(n\log n)$ - then we may use HeapSort. </p>&#xA;&#xA;<p>We may assume ...
algorithms sorting arrays
1
Sorting array containing elements from $\{1,\ldots,k\}$ in place in $O(n\log k)$ -- (algorithms sorting arrays) <p>An array $a[1,\ldots,n] \subseteq \{1,\ldots, k\}$ is given, where $k &lt; \sqrt{n}$.<br>&#xA;Our goal is a project algorithm which sorts it in place and in time $O(n\log k)$.<br>&#xA;We assume that $k &lt...
habedi/stack-exchange-dataset
49,447
how to binarize an image?
<p>I don't want to binarize a certain image through another program, I want to know how to binarize things myself. All I know is that there is something to do with a threshold and if it is above the threshold it is either 1 or 0 and the opposite if below. My images are using RGB but I can also use HSB or HSV. I just wa...
algorithms image processing
1
how to binarize an image? -- (algorithms image processing) <p>I don't want to binarize a certain image through another program, I want to know how to binarize things myself. All I know is that there is something to do with a threshold and if it is above the threshold it is either 1 or 0 and the opposite if below. My im...
habedi/stack-exchange-dataset
49,448
Union and intersection of a regular and a non-regular language
<p>Lets say we have $L_1$, which is a regular language and $L_2$ which is not. Are $L_1 \cap L_2$, $L_1 \cup L_2$ , $L_1$ \ $L_2$ and $L_1 \cdot L_2$ are always non-regular languages? </p>&#xA;&#xA;<p>We know that two regular languages always gives us a regular language under all of the above. I can't find anywhere any...
formal languages regular languages closure properties
1
Union and intersection of a regular and a non-regular language -- (formal languages regular languages closure properties) <p>Lets say we have $L_1$, which is a regular language and $L_2$ which is not. Are $L_1 \cap L_2$, $L_1 \cup L_2$ , $L_1$ \ $L_2$ and $L_1 \cdot L_2$ are always non-regular languages? </p>&#xA;&#xA;...
habedi/stack-exchange-dataset
49,452
Is $\log^2n = O(n)$ or $n = O(\log^2n)$ true?
<p>I'm trying to figure out if:</p>&#xA;&#xA;<ol>&#xA;<li>$\log^2n = O(n)$ and</li>&#xA;<li>$ n = O(\log^2n)$</li>&#xA;</ol>&#xA;&#xA;<p>are true or if one or both are false.</p>&#xA;&#xA;<p>So far I've concluded that both are false because if $n = 8$ for the first one, then $\log^2 8 = O(8)$ which is false since it si...
asymptotics landau notation
1
Is $\log^2n = O(n)$ or $n = O(\log^2n)$ true? -- (asymptotics landau notation) <p>I'm trying to figure out if:</p>&#xA;&#xA;<ol>&#xA;<li>$\log^2n = O(n)$ and</li>&#xA;<li>$ n = O(\log^2n)$</li>&#xA;</ol>&#xA;&#xA;<p>are true or if one or both are false.</p>&#xA;&#xA;<p>So far I've concluded that both are false because ...
habedi/stack-exchange-dataset
49,453
Problems that don't have polykernel when parametrized by vertex cover
<p>Are there any problems <strong>apart from chromatic number</strong>, which is $FPT$ when parametrized by (the size of a minimum) vertex cover, and that does not admit a polykernel when parametrized by (the size of a minimum) vertex cover (under standard complexity assumptions)?</p>&#xA;
algorithms algorithm analysis parameterized complexity
1
Problems that don't have polykernel when parametrized by vertex cover -- (algorithms algorithm analysis parameterized complexity) <p>Are there any problems <strong>apart from chromatic number</strong>, which is $FPT$ when parametrized by (the size of a minimum) vertex cover, and that does not admit a polykernel when pa...
habedi/stack-exchange-dataset
49,454
Are "TM M accepts some string of length greater than 100" and "TM M accepts some string of length at most 100" decidable?
<p>I have two questions as in the title:</p>&#xA;&#xA;<ol>&#xA;<li>TM M accepts some string of length greater than 100</li>&#xA;<li>TM M accepts some string of length at most 100 </li>&#xA;</ol>&#xA;&#xA;<p>Since 1. is infinite, we can rephrase question as "does TM accept a string", which is clearly undecidable and the...
turing machines undecidability decision problem
1
Are "TM M accepts some string of length greater than 100" and "TM M accepts some string of length at most 100" decidable? -- (turing machines undecidability decision problem) <p>I have two questions as in the title:</p>&#xA;&#xA;<ol>&#xA;<li>TM M accepts some string of length greater than 100</li>&#xA;<li>TM M accepts ...
habedi/stack-exchange-dataset
49,460
Can a vectorized computation always be parallelized?
<p>If the question appears vague, I'll gladly clarify. It's not tied to a programing language. If there is a language dependency in the answer, one can place it in the context of Python, R, VB, Mathematica, Matlab, or seek clarification.</p>&#xA;&#xA;<p>Are there situations when a <strong>vectorized</strong> (aka <em>e...
parallel computing performance loops
1
Can a vectorized computation always be parallelized? -- (parallel computing performance loops) <p>If the question appears vague, I'll gladly clarify. It's not tied to a programing language. If there is a language dependency in the answer, one can place it in the context of Python, R, VB, Mathematica, Matlab, or seek cl...
habedi/stack-exchange-dataset
49,462
Why does this graph show the tightness of MST heuristic's 2-approximation bound?
<p>This is a homework problem I've been given and I've been raking my brain for hours (so I'm satisfied with some pointers). I know already that the approximation ratio cannot be worse than $2$. I have a wheel graph, where each edge has cost $1$ and the distance between all nodes which are not connected by edges is $2$...
algorithms algorithm analysis approximation traveling salesman
1
Why does this graph show the tightness of MST heuristic's 2-approximation bound? -- (algorithms algorithm analysis approximation traveling salesman) <p>This is a homework problem I've been given and I've been raking my brain for hours (so I'm satisfied with some pointers). I know already that the approximation ratio ca...
habedi/stack-exchange-dataset
49,480
Huffman Code VS Hu–Tucker Code
<p>Before I'll ask my question, let me start with my understanding of the definitions, to prevent myself with further confusion, as well as giving some background.</p>&#xA;&#xA;<p><strong>Huffman Code</strong> is the binary-code induced from a binary tree, constructed by Huffman's Algorithm.<br>&#xA;<strong>Hu–Tucker C...
binary trees huffman coding
1
Huffman Code VS Hu–Tucker Code -- (binary trees huffman coding) <p>Before I'll ask my question, let me start with my understanding of the definitions, to prevent myself with further confusion, as well as giving some background.</p>&#xA;&#xA;<p><strong>Huffman Code</strong> is the binary-code induced from a binary tree,...
habedi/stack-exchange-dataset
49,481
Shortest path that visits maximum number of strongly connected components
<p>Consider a directed graph. I need to find a path that visits maximum number of strongly connected components in that graph. If there are several such paths the desired path is the path that visits minimum number of nodes (shortest path). </p>&#xA;&#xA;<p>I have created a DAG from the directed graph and performed a ...
algorithms graphs shortest path graph traversal
1
Shortest path that visits maximum number of strongly connected components -- (algorithms graphs shortest path graph traversal) <p>Consider a directed graph. I need to find a path that visits maximum number of strongly connected components in that graph. If there are several such paths the desired path is the path that ...
habedi/stack-exchange-dataset
49,482
Periods of an LFSR with characteristic polynomial that is a product of primitive polynomials
<p>I want to find the minimal period of any state of an LFSR (except the initial state of all zeroes) whose characteristic polynomial is the product of two primitive polynomials.</p>&#xA;&#xA;<p>In particular, $f(x),g(x) \in GF(2)[x]$ are primitive polynomials of order $n$, and the characteristic polynomial of the LFSR...
polynomials pseudo random generators
1
Periods of an LFSR with characteristic polynomial that is a product of primitive polynomials -- (polynomials pseudo random generators) <p>I want to find the minimal period of any state of an LFSR (except the initial state of all zeroes) whose characteristic polynomial is the product of two primitive polynomials.</p>&#x...
habedi/stack-exchange-dataset
49,487
If the universe were predetermined, would non-deterministic automata still make sense?
<p>If the universe were governed by <a href="https://en.wikipedia.org/wiki/Predeterminism" rel="nofollow">predeterminism</a> (i.e. some deity decided in advance how everything, ever, would play out), would the notion of non-deterministic automata make sense? Or would it not, but we wouldn't know it?</p>&#xA;
automata nondeterminism philosophy
1
If the universe were predetermined, would non-deterministic automata still make sense? -- (automata nondeterminism philosophy) <p>If the universe were governed by <a href="https://en.wikipedia.org/wiki/Predeterminism" rel="nofollow">predeterminism</a> (i.e. some deity decided in advance how everything, ever, would play...
habedi/stack-exchange-dataset
49,491
Mapping reducibility vs. Turing reducibility
<p>Let $A$ and $B$ be two languages. If $A \le_{m} B$ ( reducible by mapping ) then I know that if $B$ is decidable so is $A$ and if $B$ is recognizable so is $A$. And if $A \le_{T} B$, then if $B$ is decidable so is $A$. But I can't say the same thing for recognizability which I can see by example when $A \equiv L_...
computability reductions semi decidability
1
Mapping reducibility vs. Turing reducibility -- (computability reductions semi decidability) <p>Let $A$ and $B$ be two languages. If $A \le_{m} B$ ( reducible by mapping ) then I know that if $B$ is decidable so is $A$ and if $B$ is recognizable so is $A$. And if $A \le_{T} B$, then if $B$ is decidable so is $A$. But ...
habedi/stack-exchange-dataset
49,503
Unification Functions
<p>I need to apply the unification function to unify the following expression:</p>&#xA;&#xA;<p>foo(X,X,Y) and foo(Z,p(Z),w)</p>&#xA;&#xA;<p>So far, I've determined that I must substitute 'w's for occurances of 'Y', making</p>&#xA;&#xA;<p>foo(X,X,w) and foo(Z,p(Z),w)</p>&#xA;&#xA;<p>Then, I can saw X/Z (replaces 'Z' wit...
artificial intelligence unification
1
Unification Functions -- (artificial intelligence unification) <p>I need to apply the unification function to unify the following expression:</p>&#xA;&#xA;<p>foo(X,X,Y) and foo(Z,p(Z),w)</p>&#xA;&#xA;<p>So far, I've determined that I must substitute 'w's for occurances of 'Y', making</p>&#xA;&#xA;<p>foo(X,X,w) and foo(...
habedi/stack-exchange-dataset
49,504
How to understand the storing mechanism used in external merge sort
<p>I was reading about <code>external merge sort</code> from the wikipedia article <a href="https://en.wikipedia.org/wiki/External_sorting" rel="nofollow">link</a>, according to it:</p>&#xA;&#xA;<blockquote>&#xA; <p>External sorting is required when the data being sorted do not fit&#xA; into the main memory of a comp...
algorithms algorithm analysis sorting quicksort
1
How to understand the storing mechanism used in external merge sort -- (algorithms algorithm analysis sorting quicksort) <p>I was reading about <code>external merge sort</code> from the wikipedia article <a href="https://en.wikipedia.org/wiki/External_sorting" rel="nofollow">link</a>, according to it:</p>&#xA;&#xA;<blo...
habedi/stack-exchange-dataset
49,508
Use dynamic programming to find a subset of numbers whose sum is closest to given number M
<p>Given a set $A$ of $n$ positive integers $a_1, a_2,\ldots, a_n$ and another positive integer $M$, I'm going to find a subset of numbers of $A$ whose sum is closest to $M$. In other words, I'm trying to find a subset $A′$ of $A$ such that the absolute value $|M - \sum_{a∈A′}a|$ is minimized. I only need to return the...
dynamic programming knapsack problems
1
Use dynamic programming to find a subset of numbers whose sum is closest to given number M -- (dynamic programming knapsack problems) <p>Given a set $A$ of $n$ positive integers $a_1, a_2,\ldots, a_n$ and another positive integer $M$, I'm going to find a subset of numbers of $A$ whose sum is closest to $M$. In other wo...
habedi/stack-exchange-dataset
49,511
Are some Integer programming formulations completely useless for relaxation?
<p>I was tasked with constructing an integer programming formulation for an <strong>NP</strong>-hard problem, and then with specifying its LP relaxation and the resulting approximation factor.</p>&#xA;&#xA;<p>The problem is that, while my integer programming formulation is correct and clever (I like to think), it seams...
linear programming integer programming
1
Are some Integer programming formulations completely useless for relaxation? -- (linear programming integer programming) <p>I was tasked with constructing an integer programming formulation for an <strong>NP</strong>-hard problem, and then with specifying its LP relaxation and the resulting approximation factor.</p>&#x...
habedi/stack-exchange-dataset
49,521
How to resize a large, distributed hash table?
<p>Many hash table implementations found in programming languages (such as Java's HashMap or Python's dict) dynamically increase the size of the hash table once the number of items reaches a certain threshold. In these cases, resizing the hash table means allocating a new, larger memory area, re-hashing all the items a...
data structures distributed systems hash tables
1
How to resize a large, distributed hash table? -- (data structures distributed systems hash tables) <p>Many hash table implementations found in programming languages (such as Java's HashMap or Python's dict) dynamically increase the size of the hash table once the number of items reaches a certain threshold. In these c...
habedi/stack-exchange-dataset
49,529
What does Godels Incompleteness theorem "true but unprovable" mean?
<p>I have asked this on the "computer science chat" ( <a href="https://area51.meta.stackexchange.com/users/51280/vzn">vzn</a> tried to explain me ) . I even watched a couple a videos to understand the theorem but still cannot convince myself. The following is the way the Godel's Incompleteness theorem is proved in Sips...
logic type theory
1
What does Godels Incompleteness theorem "true but unprovable" mean? -- (logic type theory) <p>I have asked this on the "computer science chat" ( <a href="https://area51.meta.stackexchange.com/users/51280/vzn">vzn</a> tried to explain me ) . I even watched a couple a videos to understand the theorem but still cannot con...
habedi/stack-exchange-dataset
49,531
Why do we distinguish between term abstraction and type abstraction in System F?
<p>In System F, we distinguish between types and terms. Types are defined by the following BNF:</p>&#xA;&#xA;<p>\begin{align}&#xA;A, B ::=&amp;~\alpha &amp;&amp; \text{(type variable)} \\&#xA; &amp;|~A \rightarrow B &amp;&amp; \text{(function type)} \\&#xA; &amp;|~\forall \alpha. B &amp;&amp; \text{(univers...
lambda calculus type theory functional programming
1
Why do we distinguish between term abstraction and type abstraction in System F? -- (lambda calculus type theory functional programming) <p>In System F, we distinguish between types and terms. Types are defined by the following BNF:</p>&#xA;&#xA;<p>\begin{align}&#xA;A, B ::=&amp;~\alpha &amp;&amp; \text{(type variable)...
habedi/stack-exchange-dataset
49,532
Counting an integer's divisors without just enumerating them (or estimating if not possible)?
<p>I'm trying to count the number of divisors an integer $n$ has. <strong>The simple way</strong> to do this is to just enumerate all integers from 1 to $\sqrt{n}$, and count how many integers evenly divide $n$.</p>&#xA;&#xA;<p><strong>For example</strong>, 28 has six divisors (1, 2, 4, 7, 14, 28). 15 has four (1, 3, ...
arithmetic number theory integers
1
Counting an integer's divisors without just enumerating them (or estimating if not possible)? -- (arithmetic number theory integers) <p>I'm trying to count the number of divisors an integer $n$ has. <strong>The simple way</strong> to do this is to just enumerate all integers from 1 to $\sqrt{n}$, and count how many in...
habedi/stack-exchange-dataset
49,540
Understanding of Turing's Answer to the Entscheidungsproblem
<p>I apologize if this question has been asked before, but I was not able to find a duplicate.</p>&#xA;&#xA;<p>I have just finished reading <a href="https://en.wikipedia.org/wiki/The_Annotated_Turing" rel="nofollow">The Annotated Turing</a> and I am a bit confused. </p>&#xA;&#xA;<p>From what I understand, the Entscheid...
computability turing machines logic decision problem incompleteness
1
Understanding of Turing's Answer to the Entscheidungsproblem -- (computability turing machines logic decision problem incompleteness) <p>I apologize if this question has been asked before, but I was not able to find a duplicate.</p>&#xA;&#xA;<p>I have just finished reading <a href="https://en.wikipedia.org/wiki/The_Ann...
habedi/stack-exchange-dataset
49,542
Removing common background in image processing phase for classification
<p>I'm trying to build a machine learning classifier that can detect which object is in an image. I have a labled training set of images and am currently in the image processing phase. Each of these images has one of the objects. However, almost all images have these objects embedded in a very common background color a...
machine learning image processing computer vision
1
Removing common background in image processing phase for classification -- (machine learning image processing computer vision) <p>I'm trying to build a machine learning classifier that can detect which object is in an image. I have a labled training set of images and am currently in the image processing phase. Each of ...
habedi/stack-exchange-dataset
49,544
Is Post Correspondence Problem in NP?
<p>I just read some pages in Sipser's book Introduction to Theory of Computation about Post Correspondence Problem, and I'm thinking that PCP is actually in NP. The certifier is: for an input configuration of pile &#xA;$$(t_1/b_1, t_2/b_2,...t_n/b_n)$$&#xA;concatenating $t_1, t_2,...,t_n$ as a string $t$ and concatenat...
complexity theory decision problem np
1
Is Post Correspondence Problem in NP? -- (complexity theory decision problem np) <p>I just read some pages in Sipser's book Introduction to Theory of Computation about Post Correspondence Problem, and I'm thinking that PCP is actually in NP. The certifier is: for an input configuration of pile &#xA;$$(t_1/b_1, t_2/b_2,...
habedi/stack-exchange-dataset
49,551
Why is the set of all regular expressions classified as context-free, instead of regular?
<p>As I understand regular languages can be closed under concatenation, so can I concatenate the set of all regular expressions to classify them as regular?</p>&#xA;
formal languages regular languages closure properties
1
Why is the set of all regular expressions classified as context-free, instead of regular? -- (formal languages regular languages closure properties) <p>As I understand regular languages can be closed under concatenation, so can I concatenate the set of all regular expressions to classify them as regular?</p>&#xA;
habedi/stack-exchange-dataset
49,557
Is {ww^r ww^r} a context-free language?
<p>Is the language $L = \{w w^r w w^r \mid w \in \Sigma^*\}$ context-free? ($w^r$ is the reversal of $w$.)</p>&#xA;&#xA;<p>I heard that by using the pumping lemma, we can only prove that a language is not context-free, but can't prove that a language is context-free. I tried the pumping lemma and we can produce the lan...
formal languages context free pumping lemma
1
Is {ww^r ww^r} a context-free language? -- (formal languages context free pumping lemma) <p>Is the language $L = \{w w^r w w^r \mid w \in \Sigma^*\}$ context-free? ($w^r$ is the reversal of $w$.)</p>&#xA;&#xA;<p>I heard that by using the pumping lemma, we can only prove that a language is not context-free, but can't pr...
habedi/stack-exchange-dataset
49,563
Example of height-balanced tree that is not weight-balanced
<p>Following this question : <a href="https://cs.stackexchange.com/questions/3515/two-definitions-of-balanced-binary-trees">Two definitions of balanced binary trees</a></p>&#xA;&#xA;<p>I am having a hard time making sense of the proofs provided and I'm looking for an example of a simple binary tree that is <em>height-b...
data structures binary trees search trees balanced search trees
1
Example of height-balanced tree that is not weight-balanced -- (data structures binary trees search trees balanced search trees) <p>Following this question : <a href="https://cs.stackexchange.com/questions/3515/two-definitions-of-balanced-binary-trees">Two definitions of balanced binary trees</a></p>&#xA;&#xA;<p>I am h...
habedi/stack-exchange-dataset
49,564
$2$-sorted array. How to sort it in minimal number of comparisons ?
<p>It is given array $2$-sorted array $a[1..n]$. $2$-sorted denotes that $a[1]\le a[3]\le...\le$ and $a[2]\le a[4]\le ..\le$ </p>&#xA;&#xA;<p>Obviously we may split array into two sorted arrays and then merge two arrays - it requires $n-2$ comparisons. However I think about lower bound. I believe that $n-2$ is lower...
algorithms sorting lower bounds
1
$2$-sorted array. How to sort it in minimal number of comparisons ? -- (algorithms sorting lower bounds) <p>It is given array $2$-sorted array $a[1..n]$. $2$-sorted denotes that $a[1]\le a[3]\le...\le$ and $a[2]\le a[4]\le ..\le$ </p>&#xA;&#xA;<p>Obviously we may split array into two sorted arrays and then merge two ...
habedi/stack-exchange-dataset
49,565
Benes (Fat Tree) Network for number of inputs/outputs that is not 2^n
<p>I was reading about Benes Network construction in this <a href="http://dl.acm.org/citation.cfm?id=995703" rel="nofollow">book</a>.&#xA;Their construction is easy for a number of inputs and outputs that is an exponent of two. </p>&#xA;&#xA;<p>However it seems to me that for a number of i/o that falls between $2^{n}$ ...
computer networks network topology
1
Benes (Fat Tree) Network for number of inputs/outputs that is not 2^n -- (computer networks network topology) <p>I was reading about Benes Network construction in this <a href="http://dl.acm.org/citation.cfm?id=995703" rel="nofollow">book</a>.&#xA;Their construction is easy for a number of inputs and outputs that is an...
habedi/stack-exchange-dataset
49,572
Most Efficient Way to Map Generic Input To Generic Output
<p>Lookup tables are one way to map x values to f(x) values. This lets you do computation in advance, and can give a low cost (performance wise) answer to complex calculations when they are needed in performance intensive applications.</p>&#xA;&#xA;<p>Another method to map x values to f(x) values is to use the chinese...
computability encoding scheme
1
Most Efficient Way to Map Generic Input To Generic Output -- (computability encoding scheme) <p>Lookup tables are one way to map x values to f(x) values. This lets you do computation in advance, and can give a low cost (performance wise) answer to complex calculations when they are needed in performance intensive appl...
habedi/stack-exchange-dataset
49,575
Context-free language and undecidable
<p>I am working on my midterm sample problems and got stuck on this one. Is this language undecidable?</p>&#xA;&#xA;<p>$\qquad L = \{\langle G_1, G_2 \rangle: G_1, G_2 \text{ are CFG and have strings that can be parsed in both grammars }\}$</p>&#xA;&#xA;<p>Is this one the same as $L' = \{\langle G_1, G_2 \rangle: L(G...
computability context free formal grammars
1
Context-free language and undecidable -- (computability context free formal grammars) <p>I am working on my midterm sample problems and got stuck on this one. Is this language undecidable?</p>&#xA;&#xA;<p>$\qquad L = \{\langle G_1, G_2 \rangle: G_1, G_2 \text{ are CFG and have strings that can be parsed in both gramm...
habedi/stack-exchange-dataset
49,593
Find hamilton cycle in a directed graph reduced to sat problem
<p>I need to find a <strong>Hamiltonian cycle</strong> in a directed graph using propositional logic, and to solve it by sat solver. So after I couldn't find a working solution, I found a paper that describes how to construct a CNF formula to find an <strong>Hamiltonian path</strong>:</p>&#xA;&#xA;<p><code>Xi,j</code> ...
graphs satisfiability propositional logic hamiltonian path hamiltonian circuit
1
Find hamilton cycle in a directed graph reduced to sat problem -- (graphs satisfiability propositional logic hamiltonian path hamiltonian circuit) <p>I need to find a <strong>Hamiltonian cycle</strong> in a directed graph using propositional logic, and to solve it by sat solver. So after I couldn't find a working solut...
habedi/stack-exchange-dataset
49,602
Where are the address, control and data buses on a computer
<p>So have been reading up on data buses, address buses and control buses and I understand what they do, but am confused about where they can physically be found. Some books/sites I have found state that they are inside of the CPU, some state that they transmit data all over the computer. E.g. the control bus can send ...
computer architecture cpu
1
Where are the address, control and data buses on a computer -- (computer architecture cpu) <p>So have been reading up on data buses, address buses and control buses and I understand what they do, but am confused about where they can physically be found. Some books/sites I have found state that they are inside of the CP...
habedi/stack-exchange-dataset
49,604
Approximate Subset Sum with negative numbers
<p>I am interested in the approximation version of the Subset Sum problem with negative numbers.&#xA;<a href="https://en.wikipedia.org/wiki/Subset_sum_problem#Polynomial_time_approximate_algorithm" rel="nofollow noreferrer">Wikipedia</a> says there is an FPTAS algorithm for SS. That Wikipedia page states:</p>&#xA;&#xA;...
complexity theory np complete reductions approximation
1
Approximate Subset Sum with negative numbers -- (complexity theory np complete reductions approximation) <p>I am interested in the approximation version of the Subset Sum problem with negative numbers.&#xA;<a href="https://en.wikipedia.org/wiki/Subset_sum_problem#Polynomial_time_approximate_algorithm" rel="nofollow nor...
habedi/stack-exchange-dataset
49,612
Term for shifting work to idle machines
<p>I am looking for a term here. A while ago, i was told about a network in which all the computers are connected in parallel, and when a computer is idle, the central server sends heavy cpu usage tasks to that idle computer. </p>&#xA;&#xA;<p>This is often used in pharmaceutical companies working on protein structure c...
terminology distributed systems computer networks
1
Term for shifting work to idle machines -- (terminology distributed systems computer networks) <p>I am looking for a term here. A while ago, i was told about a network in which all the computers are connected in parallel, and when a computer is idle, the central server sends heavy cpu usage tasks to that idle computer....
habedi/stack-exchange-dataset
49,615
What is an "encoding" of a TM?
<p>I'm currently working on a reduction from $A_{TM}$ to another language, and have been reading through some example proofs. I've come across the situation where, for example, we have $L = \{ \langle M,w \rangle | \text{ ...etc} \}$, where obviously this would normally stand for $M$ being a TM and $w$ being a string. ...
turing machines automata reductions encoding scheme
1
What is an "encoding" of a TM? -- (turing machines automata reductions encoding scheme) <p>I'm currently working on a reduction from $A_{TM}$ to another language, and have been reading through some example proofs. I've come across the situation where, for example, we have $L = \{ \langle M,w \rangle | \text{ ...etc} \}...
habedi/stack-exchange-dataset
49,622
Proving that $A=\{w_{2i}|w_{2i}\not\in L(M_i)\}$ is not Turing-recognizable
<p>In this problem, $w_{2i}$ is the $2i$th string in the lexicographic order of binary strings and $M_i$ is the TM whose binary code is $w_i$.&#xA;We are given the diagonalization language $A_D=\{w_i \mid w_i \notin L(M_i)\}$. We know $A_D$ is not Turing Recognizable.</p>&#xA;&#xA;<p>Basically, $w_i$ is the $i$th strin...
turing machines
1
Proving that $A=\{w_{2i}|w_{2i}\not\in L(M_i)\}$ is not Turing-recognizable -- (turing machines) <p>In this problem, $w_{2i}$ is the $2i$th string in the lexicographic order of binary strings and $M_i$ is the TM whose binary code is $w_i$.&#xA;We are given the diagonalization language $A_D=\{w_i \mid w_i \notin L(M_i)\...
habedi/stack-exchange-dataset
49,627
Context-free languages not closed under making them "extension-free"
<p>For a language $L$, define:&#xA;$$&#xA;NE(L) = \{x \in L : x \text{ is not the proper prefix of any string in } L\}&#xA;$$</p>&#xA;&#xA;<p>I'm trying to show context-free languages are <em>not</em> closed under this operation.&#xA;I've been struggling for a long time now trying to find a counterexample, that is, a l...
formal languages context free closure properties
1
Context-free languages not closed under making them "extension-free" -- (formal languages context free closure properties) <p>For a language $L$, define:&#xA;$$&#xA;NE(L) = \{x \in L : x \text{ is not the proper prefix of any string in } L\}&#xA;$$</p>&#xA;&#xA;<p>I'm trying to show context-free languages are <em>not</...
habedi/stack-exchange-dataset
49,634
Dempster-Shafer theory initial belief values
<p>I am looking to implement D-S Theory in my (computer science) research, I'll be using it to determine the probability that a triggered sensor event is a true positive. </p>&#xA;&#xA;<p>How would you calculate an initial belief value without having the ability to perform data mining on a dataset (a cold start)?</p>&#...
probability theory
1
Dempster-Shafer theory initial belief values -- (probability theory) <p>I am looking to implement D-S Theory in my (computer science) research, I'll be using it to determine the probability that a triggered sensor event is a true positive. </p>&#xA;&#xA;<p>How would you calculate an initial belief value without having ...
habedi/stack-exchange-dataset
49,638
Do Self Types make the Calculus of Inductive Constructions obsolete?
<p>Self Types are an extension of the Calculus of Constructions [1] that allow the language to express algebraic datatypes encoded through the Scott Encoding. The Scott Encoding provides one the ability to pattern-match in <code>O(1)</code>, which is one of the main motivators for the inclusion of inductive definitions...
lambda calculus type theory functional programming inductive datatypes
1
Do Self Types make the Calculus of Inductive Constructions obsolete? -- (lambda calculus type theory functional programming inductive datatypes) <p>Self Types are an extension of the Calculus of Constructions [1] that allow the language to express algebraic datatypes encoded through the Scott Encoding. The Scott Encodi...
habedi/stack-exchange-dataset
49,639
Proof of APSPACE = EXP
<p>I have been reading Computational Complexity A Modern Approach book and this proof wasn't given in the book. </p>&#xA;&#xA;<p>Please give a semi-detailed proof of this. I have found a paper which has this proof(by Chandra, Kozen et al.) but found it too hard to understand.</p>&#xA;
complexity theory time complexity complexity classes space complexity
1
Proof of APSPACE = EXP -- (complexity theory time complexity complexity classes space complexity) <p>I have been reading Computational Complexity A Modern Approach book and this proof wasn't given in the book. </p>&#xA;&#xA;<p>Please give a semi-detailed proof of this. I have found a paper which has this proof(by Chand...
habedi/stack-exchange-dataset
49,640
Hash Table: Relation between position of a value and Hash table size
<p>I need to know whether hash table size, $S$ has any impact on distribution of a value in hash table. </p>&#xA;&#xA;<p>At the moment I'm using SHA512 and I can tolerate up to 50 elements in any bucket, and I have $10^6$ elements; I set hash table length to $S=50000$. This is far more larger than what is suggested in ...
data structures hash tables
1
Hash Table: Relation between position of a value and Hash table size -- (data structures hash tables) <p>I need to know whether hash table size, $S$ has any impact on distribution of a value in hash table. </p>&#xA;&#xA;<p>At the moment I'm using SHA512 and I can tolerate up to 50 elements in any bucket, and I have $10...
habedi/stack-exchange-dataset
49,652
Automaton for 'almost' same word in language
<p>I have some finite language L, which is regular.</p>&#xA;&#xA;<p>I want to find a finite automaton (DFA/NFA) that for every word w in L, it accepts any word with the same length but only with 1 char diffrence.</p>&#xA;&#xA;<p>I thought about maybe accept DFA for L, because it a regular language and think about an NF...
automata finite automata
1
Automaton for 'almost' same word in language -- (automata finite automata) <p>I have some finite language L, which is regular.</p>&#xA;&#xA;<p>I want to find a finite automaton (DFA/NFA) that for every word w in L, it accepts any word with the same length but only with 1 char diffrence.</p>&#xA;&#xA;<p>I thought about ...
habedi/stack-exchange-dataset
49,658
Convolutional Neural Network Example in Tensorflow
<p>I want to ask the dimension change in different convolution and max-pooling layer. I am referring to the example in TensorFlow tutorial:</p>&#xA;&#xA;<p><a href="http://tensorflow.org/tutorials/mnist/pros/index.html#deep-mnist-for-experts" rel="noreferrer">http://tensorflow.org/tutorials/mnist/pros/index.html#deep-m...
neural networks
1
Convolutional Neural Network Example in Tensorflow -- (neural networks) <p>I want to ask the dimension change in different convolution and max-pooling layer. I am referring to the example in TensorFlow tutorial:</p>&#xA;&#xA;<p><a href="http://tensorflow.org/tutorials/mnist/pros/index.html#deep-mnist-for-experts" rel="...
habedi/stack-exchange-dataset
49,667
Set of Turing machines $S$ such that any $A \in S$ halts on input the description of any $B \in S$
<p>Does there exist a maximal set of Turing machines $S$ over the alphabet $\{0,1\}$ such that any $A \in S$ halts on input the description of any $B \in S$?</p>&#xA;&#xA;<p>Take S to be the set of deciders. Then S satisfies the property, but is not maximal, because for example we can take:</p>&#xA;&#xA;<ul>&#xA;<li><p...
computability turing machines
1
Set of Turing machines $S$ such that any $A \in S$ halts on input the description of any $B \in S$ -- (computability turing machines) <p>Does there exist a maximal set of Turing machines $S$ over the alphabet $\{0,1\}$ such that any $A \in S$ halts on input the description of any $B \in S$?</p>&#xA;&#xA;<p>Take S to be...
habedi/stack-exchange-dataset
49,668
Variations of Greedy Algorithm
<p>What is the definition of an "orthogonal greedy algorithm"?</p>&#xA;&#xA;<p>What is the definition of a "relaxed greedy algorithms"?</p>&#xA;&#xA;<p>Can you give an example to illustrate how these notions differ from ordinary greedy algorithms?</p>&#xA;&#xA;<p><a href="https://en.wikipedia.org/wiki/Greedy_algorithm"...
algorithms terminology greedy algorithms
1
Variations of Greedy Algorithm -- (algorithms terminology greedy algorithms) <p>What is the definition of an "orthogonal greedy algorithm"?</p>&#xA;&#xA;<p>What is the definition of a "relaxed greedy algorithms"?</p>&#xA;&#xA;<p>Can you give an example to illustrate how these notions differ from ordinary greedy algorit...
habedi/stack-exchange-dataset
49,681
Macro expansion is done in which phase of a compiler?
<p>This is question raised by my teacher in the class room. I don't have enough knowledge about phases of compiler and macro expansion. Could someone help me in finding out proper solution to this </p>&#xA;
compilers
1
Macro expansion is done in which phase of a compiler? -- (compilers) <p>This is question raised by my teacher in the class room. I don't have enough knowledge about phases of compiler and macro expansion. Could someone help me in finding out proper solution to this </p>&#xA;
habedi/stack-exchange-dataset
49,699
How to make a NFA (or DFA) from $\varepsilon$NFA?
<p>I need to build a DFA from <span class="math-container">$\varepsilon$</span>NFA, so first of all I assume that I need to convert the <span class="math-container">$\varepsilon$</span>NFA to NFA and then to DFA (because I know the method of converting from NFA to DFA, and we learn how to remove <span class="math-conta...
automata finite automata
1
How to make a NFA (or DFA) from $\varepsilon$NFA? -- (automata finite automata) <p>I need to build a DFA from <span class="math-container">$\varepsilon$</span>NFA, so first of all I assume that I need to convert the <span class="math-container">$\varepsilon$</span>NFA to NFA and then to DFA (because I know the method o...
habedi/stack-exchange-dataset
49,700
Application Ambiguity in Untyped Lambda Calculus
<p>So, untyped lambda calculus has the following formal grammar for its terms:</p>&#xA;&#xA;<p>$$e::= x \mid \lambda x . e \mid e_1 e_2$$</p>&#xA;&#xA;<p>Usually this is presented in some ML-esque language as (using de Bruijn indices)</p>&#xA;&#xA;<pre><code>data term = variable Nat | lambda term | apply term term&#xA;...
lambda calculus
1
Application Ambiguity in Untyped Lambda Calculus -- (lambda calculus) <p>So, untyped lambda calculus has the following formal grammar for its terms:</p>&#xA;&#xA;<p>$$e::= x \mid \lambda x . e \mid e_1 e_2$$</p>&#xA;&#xA;<p>Usually this is presented in some ML-esque language as (using de Bruijn indices)</p>&#xA;&#xA;<p...
habedi/stack-exchange-dataset
49,704
Conjectured NP-complete problems
<p>Assume P != NP. Then there are many examples of problems in NP that are known not to be NP-complete, like 2-SAT, and many that are conjectured not to be NP-complete, like factorization. However, are there any problems that are widely conjectured but not known to be NP-complete?</p>&#xA;
complexity theory reference request np complete
1
Conjectured NP-complete problems -- (complexity theory reference request np complete) <p>Assume P != NP. Then there are many examples of problems in NP that are known not to be NP-complete, like 2-SAT, and many that are conjectured not to be NP-complete, like factorization. However, are there any problems that are wide...
habedi/stack-exchange-dataset
49,710
Why clear the child's and not the parent's mark in Fibonacci heaps?
<p>According to Cormen et al.'s <a href="http://staff.ustc.edu.cn/~csli/graduate/algorithms/book6/chap21.htm" rel="nofollow">Introduction to Algorithms chapter 21 on Fibonacci heaps</a> (3rd edition), the FIB-HEAP-LINK($H$, $y$, $x$) clears mark of $y$ which will in the end be the child on the resulting merge. I just d...
data structures heaps
1
Why clear the child's and not the parent's mark in Fibonacci heaps? -- (data structures heaps) <p>According to Cormen et al.'s <a href="http://staff.ustc.edu.cn/~csli/graduate/algorithms/book6/chap21.htm" rel="nofollow">Introduction to Algorithms chapter 21 on Fibonacci heaps</a> (3rd edition), the FIB-HEAP-LINK($H$, $...
habedi/stack-exchange-dataset
49,742
Cyber Security - recommended reading
<p>I'm applying for a doctoral training in Cyber Security, although I come from a maths background. I've been told that my background meets the entry criteria, although for my application I would like to be able to say that I've looked into Cyber Security it at least some detail.</p>&#xA;&#xA;<p>Given that I will have ...
reference request
1
Cyber Security - recommended reading -- (reference request) <p>I'm applying for a doctoral training in Cyber Security, although I come from a maths background. I've been told that my background meets the entry criteria, although for my application I would like to be able to say that I've looked into Cyber Security it a...
habedi/stack-exchange-dataset
49,746
Number of special paths between two nodes
<p>Consider a directed graph. Each node in this graph has an integer label. We want to count the number of special paths between <code>source</code> and <code>sink</code>. Let's define a variable named <code>value</code>. Every path starts with <code>value = label[source]</code>. When we move from node A to B value cha...
algorithms graphs number theory
1
Number of special paths between two nodes -- (algorithms graphs number theory) <p>Consider a directed graph. Each node in this graph has an integer label. We want to count the number of special paths between <code>source</code> and <code>sink</code>. Let's define a variable named <code>value</code>. Every path starts w...
habedi/stack-exchange-dataset
49,759
What does it mean to fool a function?
<p>In computer science papers, I see about the term 'fooling' a function.</p>&#xA;&#xA;<p>What does it mean to fool a function against a particular complexity class? Why is it important?</p>&#xA;
complexity theory terminology pseudo random generators
1
What does it mean to fool a function? -- (complexity theory terminology pseudo random generators) <p>In computer science papers, I see about the term 'fooling' a function.</p>&#xA;&#xA;<p>What does it mean to fool a function against a particular complexity class? Why is it important?</p>&#xA;
habedi/stack-exchange-dataset
49,766
Why arrival process of packets at a switch is not a Poisson Process?
<p>"Packet arrivals are not Poisson<br>&#xA;.... but some events are, such as web requests and new flow arrivals"<br>&#xA;I know since the network traffic is very bursty, they are not Poisson.<br>&#xA;But I am unable to understand what "new flow arrivals" mean here and&#xA;how web requests and new flow arrivals can be ...
terminology probability theory computer networks modelling
1
Why arrival process of packets at a switch is not a Poisson Process? -- (terminology probability theory computer networks modelling) <p>"Packet arrivals are not Poisson<br>&#xA;.... but some events are, such as web requests and new flow arrivals"<br>&#xA;I know since the network traffic is very bursty, they are not Poi...
habedi/stack-exchange-dataset
49,770
Which "ID" extraction is correct?
<p>This question related to attack on the LMAP++ the result of extracting ID from the messages.&#xA;In <a href="http://elibrary.palcomtech.ac.id/wp-content/uploads/Cryptology-and-Network-Security.pdf" rel="nofollow">Passive Attack on RFID LMAP++ Authentication Protocolm, page 188</a></p>&#xA;&#xA;<pre><code>ID = C ⊕ ID...
logic security
1
Which "ID" extraction is correct? -- (logic security) <p>This question related to attack on the LMAP++ the result of extracting ID from the messages.&#xA;In <a href="http://elibrary.palcomtech.ac.id/wp-content/uploads/Cryptology-and-Network-Security.pdf" rel="nofollow">Passive Attack on RFID LMAP++ Authentication Proto...
habedi/stack-exchange-dataset
49,771
What NP decision problems are not self-reducible?
<p>So we just learned about self-reducibility in class. My professor and our textbook would not commit to saying that all problems in NP are self-reducible, but there didn't seem to be any examples of problems that are not. I was wondering if there are any examples, or if it's just a situation where you can't prove a...
complexity theory reductions decision problem np
1
What NP decision problems are not self-reducible? -- (complexity theory reductions decision problem np) <p>So we just learned about self-reducibility in class. My professor and our textbook would not commit to saying that all problems in NP are self-reducible, but there didn't seem to be any examples of problems that ...
habedi/stack-exchange-dataset
49,777
Is greedy algorithm the best algorithm for set cover problem?
<blockquote>&#xA; <p>Theorem: Unless $NP \subset DTIME (n^{O(\log \log n)})$, there is no $(1-o(1))\ln n$-approximation for set cover problem.</p>&#xA;</blockquote>&#xA;&#xA;<p>I am a bit confused by this theorem. As we know, greedy algorithm is $(\ln n+1)$-approximation, does this mean greedy algorithm is almost the ...
approximation greedy algorithms set cover
1
Is greedy algorithm the best algorithm for set cover problem? -- (approximation greedy algorithms set cover) <blockquote>&#xA; <p>Theorem: Unless $NP \subset DTIME (n^{O(\log \log n)})$, there is no $(1-o(1))\ln n$-approximation for set cover problem.</p>&#xA;</blockquote>&#xA;&#xA;<p>I am a bit confused by this theor...
habedi/stack-exchange-dataset
49,785
How do I prove that a language is deletion closed?
<p>For example, how could I prove that the following language is deletion closed:</p>&#xA;&#xA;<p>{$a^k$$b^j$ : $j$, $k$ $\geqslant$ 0}</p>&#xA;&#xA;<p>The reason seems obvious to me, I just can't see a way to prove it. </p>&#xA;
formal languages regular languages proof techniques closure properties
1
How do I prove that a language is deletion closed? -- (formal languages regular languages proof techniques closure properties) <p>For example, how could I prove that the following language is deletion closed:</p>&#xA;&#xA;<p>{$a^k$$b^j$ : $j$, $k$ $\geqslant$ 0}</p>&#xA;&#xA;<p>The reason seems obvious to me, I just ca...
habedi/stack-exchange-dataset
49,787
Finding regular expression for a language with more substring of one type than from another
<p>Take the alphabet A={0,1} I need to build a regular expression for the language with less or equal substrings 011 than 110. </p>&#xA;&#xA;<p>I tried to figure out what would be the finite automata but I'm not to sure. &#xA;I also tried to proof it isn't regular using Myhill-Nerode theorem but the problem is the lang...
regular languages finite automata regular expressions
1
Finding regular expression for a language with more substring of one type than from another -- (regular languages finite automata regular expressions) <p>Take the alphabet A={0,1} I need to build a regular expression for the language with less or equal substrings 011 than 110. </p>&#xA;&#xA;<p>I tried to figure out wha...
habedi/stack-exchange-dataset
49,792
Effect of value of k in K-Nearest Neighbor
<p>In K-Nearest Neighbor the value of k decides the accuracy of classification. What are the pros and cons of choosing smaller value for k and larger value for k?</p>&#xA;
machine learning artificial intelligence classification
1
Effect of value of k in K-Nearest Neighbor -- (machine learning artificial intelligence classification) <p>In K-Nearest Neighbor the value of k decides the accuracy of classification. What are the pros and cons of choosing smaller value for k and larger value for k?</p>&#xA;
habedi/stack-exchange-dataset
49,796
Complexity of covering subset of the monoid $(\{0,1\}^n, \text{OR})$
<p>(At the very bottom of this, I will shortly describe the motivation for this question.)</p>&#xA;&#xA;<p>Assume we have a commutative monoid $(G,\circ)$, i.e. a set $G$ with a commutative binary operation $\circ$ that satisfies associativity and the existence of a neutral element. The task is as follows: given some $...
complexity theory optimization algebra
1
Complexity of covering subset of the monoid $(\{0,1\}^n, \text{OR})$ -- (complexity theory optimization algebra) <p>(At the very bottom of this, I will shortly describe the motivation for this question.)</p>&#xA;&#xA;<p>Assume we have a commutative monoid $(G,\circ)$, i.e. a set $G$ with a commutative binary operation ...
habedi/stack-exchange-dataset
49,811
How is this algorithm average case derived?
<p>For a simple linear search on an unsorted list my textbook says the following:</p>&#xA;&#xA;<blockquote>&#xA; <p>To determine the average case, you add the number of iterations required to find the target at each possible position and divide the sum by n. Thus, the algorithm performs (n + n - 1 + n -2 + ... + 1)/n...
algorithm analysis runtime analysis search algorithms average case
1
How is this algorithm average case derived? -- (algorithm analysis runtime analysis search algorithms average case) <p>For a simple linear search on an unsorted list my textbook says the following:</p>&#xA;&#xA;<blockquote>&#xA; <p>To determine the average case, you add the number of iterations required to find the ta...
habedi/stack-exchange-dataset
49,815
How can I compare two different neural networks, from a theorical point of view?
<p>Let's say I have a problem (i.e. Given f(x), find x) and two neural networks(i.e. feedforward and recurrent). I would like to know if one works better than the other one. I could run the twos on a computer, but other programs might interfere and I wouldn't know if the implementations I'm running are really the best ...
machine learning artificial intelligence neural networks
1
How can I compare two different neural networks, from a theorical point of view? -- (machine learning artificial intelligence neural networks) <p>Let's say I have a problem (i.e. Given f(x), find x) and two neural networks(i.e. feedforward and recurrent). I would like to know if one works better than the other one. I c...
habedi/stack-exchange-dataset
49,819
Deleting useless (dead) states from a finite automaton
<p>A useless state in a finite automaton is one from which no path leads to a final state, hence no (piece of a string) is recognized out of this state. Theoretically, the algorithm to determine the useful states is trivial: Let $G$ be the set of good (useful) states and let $\Omega$ be the set of all states. Initializ...
automata optimization finite automata
1
Deleting useless (dead) states from a finite automaton -- (automata optimization finite automata) <p>A useless state in a finite automaton is one from which no path leads to a final state, hence no (piece of a string) is recognized out of this state. Theoretically, the algorithm to determine the useful states is trivia...
habedi/stack-exchange-dataset
49,822
Can a Turing Machine have infinite accept states?
<p>I'm still fairly new to Turing Machines, but I've been doing some research.</p>&#xA;&#xA;<p>I know that a Turing Machine can have an infinite tape and that it requires a finite number of states, but does it necessarily follow that a Turing Machine can have an infinite number of accept states?</p>&#xA;&#xA;<p>I keep ...
turing machines computation models
1
Can a Turing Machine have infinite accept states? -- (turing machines computation models) <p>I'm still fairly new to Turing Machines, but I've been doing some research.</p>&#xA;&#xA;<p>I know that a Turing Machine can have an infinite tape and that it requires a finite number of states, but does it necessarily follow t...
habedi/stack-exchange-dataset
49,825
How is (0|1|...|n) handled as a DFA?
<p>How is n-times regex alternation operation, e.g. (0|1|...|n), handled in a DFA (MYT algorithm)?</p>&#xA;&#xA;<p>Here are the rules for the MYT also (Converting Regular Expressions to NFAs&#xA;):<br>&#xA;<a href="https://swtch.com/~rsc/regexp/regexp1.html" rel="nofollow">https://swtch.com/~rsc/regexp/regexp1.html</a>...
finite automata regular expressions
1
How is (0|1|...|n) handled as a DFA? -- (finite automata regular expressions) <p>How is n-times regex alternation operation, e.g. (0|1|...|n), handled in a DFA (MYT algorithm)?</p>&#xA;&#xA;<p>Here are the rules for the MYT also (Converting Regular Expressions to NFAs&#xA;):<br>&#xA;<a href="https://swtch.com/~rsc/rege...
habedi/stack-exchange-dataset
49,827
What does it mean to have tokens at a state in a balancing network?
<p>I was assigned as homework:</p>&#xA;&#xA;<blockquote>&#xA; <p>Suppose we have a width-w balancing network of depth $d$ in a quiescent&#xA; state $s$ called $B$. Let $n = 2^d$. Prove that if n tokens enter the network&#xA; on the same wire, pass through the network, and exit, then $B$ will have&#xA; the same stat...
algorithms parallel computing
1
What does it mean to have tokens at a state in a balancing network? -- (algorithms parallel computing) <p>I was assigned as homework:</p>&#xA;&#xA;<blockquote>&#xA; <p>Suppose we have a width-w balancing network of depth $d$ in a quiescent&#xA; state $s$ called $B$. Let $n = 2^d$. Prove that if n tokens enter the net...
habedi/stack-exchange-dataset
49,888
What is a brief but complete explanation of a pure/dependent type system?
<p>If something is simple, then it should be completely explainable with a few words. This can be done for the λ-calculus: </p>&#xA;&#xA;<blockquote>&#xA; <p>The λ-calculus is a <strong>syntactical grammar</strong> (basically, a structure) with a <strong>reduction rule</strong> (which&#xA; means a search/replace proc...
functional programming type theory
1
What is a brief but complete explanation of a pure/dependent type system? -- (functional programming type theory) <p>If something is simple, then it should be completely explainable with a few words. This can be done for the λ-calculus: </p>&#xA;&#xA;<blockquote>&#xA; <p>The λ-calculus is a <strong>syntactical grammar...
habedi/stack-exchange-dataset
49,903
How to resolve a recurrence relation in the form of $T(n) = T(f(n))*T(g(n)) + h(n)$
<p>I am basically trying to solve the following question:</p>&#xA;&#xA;<p>Given a set $P = \{\{1\},\{2\},\dots,\{n\}\}$ of $n$ sets of elements, our aim is to merge these elements into one set.</p>&#xA;&#xA;<p>At each step, sets can be only merged pairwise.</p>&#xA;&#xA;<p>How many different ways can this merge happen?...
asymptotics recurrence relation
1
How to resolve a recurrence relation in the form of $T(n) = T(f(n))*T(g(n)) + h(n)$ -- (asymptotics recurrence relation) <p>I am basically trying to solve the following question:</p>&#xA;&#xA;<p>Given a set $P = \{\{1\},\{2\},\dots,\{n\}\}$ of $n$ sets of elements, our aim is to merge these elements into one set.</p>&#...
habedi/stack-exchange-dataset
49,915
How to show all possible implied parenthesis?
<p>Can I use recursion to find out the possible parenthesis we can add to this expression: 2*3-4*5 ?</p>&#xA;&#xA;<p>(2*(3-(4*5))) = -34</p>&#xA;&#xA;<p>((2*3)-(4*5)) = -14</p>&#xA;&#xA;<p>((2*(3-4))*5) = -10</p>&#xA;&#xA;<p>(2*((3-4)*5)) = -10</p>&#xA;&#xA;<p>(((2*3)-4)*5) = 10</p>&#xA;&#xA;<p>I am not able to find ou...
combinatorics recursion
1
How to show all possible implied parenthesis? -- (combinatorics recursion) <p>Can I use recursion to find out the possible parenthesis we can add to this expression: 2*3-4*5 ?</p>&#xA;&#xA;<p>(2*(3-(4*5))) = -34</p>&#xA;&#xA;<p>((2*3)-(4*5)) = -14</p>&#xA;&#xA;<p>((2*(3-4))*5) = -10</p>&#xA;&#xA;<p>(2*((3-4)*5)) = -10<...
habedi/stack-exchange-dataset
49,919
Don't understand the merge part of the mergesort
<p>I understand how the divide part of the algorithm works and how it is meant to spread efforts.</p>&#xA;&#xA;<p>What I don't understand is how would you merge blocks <code>[7][14]</code> and <code>[3][12]</code> or <code>[9][11]</code> and <code>[2][6]</code>. For the latter part it's easy enough as you just concaten...
algorithms sorting
1
Don't understand the merge part of the mergesort -- (algorithms sorting) <p>I understand how the divide part of the algorithm works and how it is meant to spread efforts.</p>&#xA;&#xA;<p>What I don't understand is how would you merge blocks <code>[7][14]</code> and <code>[3][12]</code> or <code>[9][11]</code> and <code...
habedi/stack-exchange-dataset
49,935
Can the isomorphic graph problem be solved in deterministic polynomial time?
<p>Here is a recent homework problem of mine:</p>&#xA;&#xA;<blockquote>&#xA; <p>Call graphs G and H isomorphic if the nodes of G may be reordered so&#xA; that it is identical to H. Let ISO = {⟨G,H⟩| G and H are isomorphic&#xA; graphs}. Show that ISO ∈ NP.</p>&#xA;</blockquote>&#xA;&#xA;<p>In order to solve this prob...
complexity theory time complexity polynomial time graph isomorphism
1
Can the isomorphic graph problem be solved in deterministic polynomial time? -- (complexity theory time complexity polynomial time graph isomorphism) <p>Here is a recent homework problem of mine:</p>&#xA;&#xA;<blockquote>&#xA; <p>Call graphs G and H isomorphic if the nodes of G may be reordered so&#xA; that it is ide...
habedi/stack-exchange-dataset
49,941
A non-mechanical way to get an infinite decidable subset of a Turing-recognizable language?
<p>There's a famous theorem that every infinite Turing-recognizable language has an infinite decidable subset. The standard proof of this result works by constructing an enumerator for the Turing-recognizable language, then including the first enumerated string in the decidable language, then the first string that come...
computability semi decidability
1
A non-mechanical way to get an infinite decidable subset of a Turing-recognizable language? -- (computability semi decidability) <p>There's a famous theorem that every infinite Turing-recognizable language has an infinite decidable subset. The standard proof of this result works by constructing an enumerator for the Tu...
habedi/stack-exchange-dataset
49,944
DFA accepts common strings, reduction to NPcomplete
<p>$B=\{\left&lt;M_1,M_2,...,M_k\right&gt;\text{ : Each $M_i$ is a DFA and&#xA;all of the $M_i$ accept some common string.} \}$</p>&#xA;&#xA;<p>I'm trying to show that B is NP-complete. I know I have to reduce it to another NP-complete problem, but I'm having a lot of trouble coming up with the algorithm that decides B...
complexity theory np complete finite automata reductions
1
DFA accepts common strings, reduction to NPcomplete -- (complexity theory np complete finite automata reductions) <p>$B=\{\left&lt;M_1,M_2,...,M_k\right&gt;\text{ : Each $M_i$ is a DFA and&#xA;all of the $M_i$ accept some common string.} \}$</p>&#xA;&#xA;<p>I'm trying to show that B is NP-complete. I know I have to red...
habedi/stack-exchange-dataset