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
20,044
Memory Consistency vs Cache Coherence
<p>Is it true that Sequential Consistency is a stronger property than Cache Coherence?</p>&#xA;&#xA;<p>According to</p>&#xA;&#xA;<blockquote>&#xA; <p>Sorin, Daniel J; Hill, Mark D; Wood, David A: <a href="http://www.morganclaypool.com/doi/abs/10.2200/S00346ED1V01Y201104CAC016">A Primer on Memory Consistency and Cache ...
computer architecture cpu cache shared memory
1
Memory Consistency vs Cache Coherence -- (computer architecture cpu cache shared memory) <p>Is it true that Sequential Consistency is a stronger property than Cache Coherence?</p>&#xA;&#xA;<p>According to</p>&#xA;&#xA;<blockquote>&#xA; <p>Sorin, Daniel J; Hill, Mark D; Wood, David A: <a href="http://www.morganclaypool...
habedi/stack-exchange-dataset
20,047
How does automatic differentiation work?
<p>What is the intuitive idea behind automatic differentiation?</p>&#xA;&#xA;<p>If I have a program which computes $f(x, y)=x^2+yx$, which steps lead to the program which computes the derivative $df/dx$ of f? </p>&#xA;&#xA;<pre><code>double f(double x, double y)&#xA;{&#xA; double res = x*x;&#xA; double res2 = x*y...
computer algebra computable analysis
1
How does automatic differentiation work? -- (computer algebra computable analysis) <p>What is the intuitive idea behind automatic differentiation?</p>&#xA;&#xA;<p>If I have a program which computes $f(x, y)=x^2+yx$, which steps lead to the program which computes the derivative $df/dx$ of f? </p>&#xA;&#xA;<pre><code>dou...
habedi/stack-exchange-dataset
20,056
Finding a O(n) solution to: max difference of pairs array question
<p>I don't know an O(n) solution to the following:</p>&#xA;&#xA;<p>Given an array of n integers, find the largest difference between any two pairs in the array: however, the larger integer must have a higher index in the array than the other.</p>&#xA;&#xA;<p>Ex: alg({9, 2, 6, 7}) = 5</p>&#xA;&#xA;<p>It seems straightfo...
algorithm analysis arrays
1
Finding a O(n) solution to: max difference of pairs array question -- (algorithm analysis arrays) <p>I don't know an O(n) solution to the following:</p>&#xA;&#xA;<p>Given an array of n integers, find the largest difference between any two pairs in the array: however, the larger integer must have a higher index in the a...
habedi/stack-exchange-dataset
20,063
What is Simultaneous Multithreading
<p>I come from an electronics background. I know that there are three types of implementations of multithreading (see <em>Computer Architecture: A Quantitative Approach, 5th Edition</em>):</p>&#xA;&#xA;<ol>&#xA;<li><p><strong>Fine-grain multithreading</strong> issues instructions for different threads after every cycle...
terminology operating systems computer architecture
1
What is Simultaneous Multithreading -- (terminology operating systems computer architecture) <p>I come from an electronics background. I know that there are three types of implementations of multithreading (see <em>Computer Architecture: A Quantitative Approach, 5th Edition</em>):</p>&#xA;&#xA;<ol>&#xA;<li><p><strong>F...
habedi/stack-exchange-dataset
20,066
Positive term for "unnegated"?
<p>I read a paper which talks about "a logic formula in which each variable appears at most twice unnegated and once negated". The term "unnegated" is double-negative, which makes it slightly unclear. Is there a more positive term to denote a variable that is not negated?</p>&#xA;&#xA;<p>I looked in an <a href="http://...
terminology logic
1
Positive term for "unnegated"? -- (terminology logic) <p>I read a paper which talks about "a logic formula in which each variable appears at most twice unnegated and once negated". The term "unnegated" is double-negative, which makes it slightly unclear. Is there a more positive term to denote a variable that is not ne...
habedi/stack-exchange-dataset
20,068
Is this grammar LR(1)
<p>I am reading parser chapter from dragon book and I found a grammar over there - </p>&#xA;&#xA;<p>$ S \rightarrow L=R $</p>&#xA;&#xA;<p>$ S \rightarrow R $</p>&#xA;&#xA;<p>$L \rightarrow *R $</p>&#xA;&#xA;<p>$L \rightarrow id $</p>&#xA;&#xA;<p>$R \rightarrow L $</p>&#xA;&#xA;<p>Now I have created some of its items, n...
formal grammars compilers parsers
1
Is this grammar LR(1) -- (formal grammars compilers parsers) <p>I am reading parser chapter from dragon book and I found a grammar over there - </p>&#xA;&#xA;<p>$ S \rightarrow L=R $</p>&#xA;&#xA;<p>$ S \rightarrow R $</p>&#xA;&#xA;<p>$L \rightarrow *R $</p>&#xA;&#xA;<p>$L \rightarrow id $</p>&#xA;&#xA;<p>$R \rightarro...
habedi/stack-exchange-dataset
20,069
Regular language concatenation with superset
<p>Let $A$ be some alphabet.</p>&#xA;&#xA;<p>$A$ itself is a regular language.</p>&#xA;&#xA;<p>$E = A^*$ is regular language over $A$. $E$ is a superset of all languages over $A$, regular or otherwise, i.e $E$ contains every possible string from symbols of $A$.</p>&#xA;&#xA;<p>Now let $L$ be some regular language over ...
formal languages regular languages closure properties
1
Regular language concatenation with superset -- (formal languages regular languages closure properties) <p>Let $A$ be some alphabet.</p>&#xA;&#xA;<p>$A$ itself is a regular language.</p>&#xA;&#xA;<p>$E = A^*$ is regular language over $A$. $E$ is a superset of all languages over $A$, regular or otherwise, i.e $E$ contai...
habedi/stack-exchange-dataset
20,070
Looking for a set implementation with small memory footprint
<p>I am looking for implementation of the set data type. That is, we have to</p>&#xA;&#xA;<ul>&#xA;<li>maintain a dynamic subset $S$ (of size $n$) from the universe $U = \{0, 1, 2, 3, \dots , u – 1\}$ of size $u$ with</li>&#xA;<li>operations <code>insert(x)</code> (add an element <code>x</code> to $S$) and <code>find(x...
data structures efficiency space complexity sets dictionaries
1
Looking for a set implementation with small memory footprint -- (data structures efficiency space complexity sets dictionaries) <p>I am looking for implementation of the set data type. That is, we have to</p>&#xA;&#xA;<ul>&#xA;<li>maintain a dynamic subset $S$ (of size $n$) from the universe $U = \{0, 1, 2, 3, \dots , ...
habedi/stack-exchange-dataset
20,078
Runtime analysis of a "find the secret number" algorithm
<blockquote>&#xA; <p>The algorithm task is to find an integer (range is not known). the function <code>guess(num)</code> returns one of three chars: '>','&lt;' or '='.<br>&#xA; Find the secret number with <code>O(logS)</code> guesses, where <code>S</code> is the secret number. You can use <code>find_secret(N1, N2)</...
algorithms algorithm analysis asymptotics runtime analysis
1
Runtime analysis of a "find the secret number" algorithm -- (algorithms algorithm analysis asymptotics runtime analysis) <blockquote>&#xA; <p>The algorithm task is to find an integer (range is not known). the function <code>guess(num)</code> returns one of three chars: '>','&lt;' or '='.<br>&#xA; Find the secret numb...
habedi/stack-exchange-dataset
20,081
Restricting longest path with 2-coloring to paths of at most constant length
<p>I am trying to create a polynomial time algorithm for a problem defined as follows:</p>&#xA;<blockquote>&#xA;<h3>c-ZPath(cZP)</h3>&#xA;<p><span class="math-container">$c$</span> is an integer constant <span class="math-container">$\geq 1$</span></p>&#xA;<p><strong>Input:</strong> An undirected graph <span class="mat...
complexity theory time complexity np complete
1
Restricting longest path with 2-coloring to paths of at most constant length -- (complexity theory time complexity np complete) <p>I am trying to create a polynomial time algorithm for a problem defined as follows:</p>&#xA;<blockquote>&#xA;<h3>c-ZPath(cZP)</h3>&#xA;<p><span class="math-container">$c$</span> is an integ...
habedi/stack-exchange-dataset
20,088
Define a list using only the Hindley-Milner type system
<p>I'm working on a small lambda calculus compiler that has a <a href="https://codereview.stackexchange.com/questions/38763/is-this-implementation-of-the-hindley-milner-algorithm-correct">working Hindley-Milner type inference system</a> and now also supports recursive let's (not in the linked code), which I understand ...
lambda calculus type theory type inference
1
Define a list using only the Hindley-Milner type system -- (lambda calculus type theory type inference) <p>I'm working on a small lambda calculus compiler that has a <a href="https://codereview.stackexchange.com/questions/38763/is-this-implementation-of-the-hindley-milner-algorithm-correct">working Hindley-Milner type ...
habedi/stack-exchange-dataset
20,090
Closure of CFL against right-quotient with regular languages
<blockquote>&#xA; <p>Let $A/B$ = $\{ w \mid wx \in A$ for some $x \in B \}$. Show that if A is context free and B is regular, then $A/B$ is context free.</p>&#xA;</blockquote>&#xA;&#xA;<p>My interpretation of this is is that we need to show that if a string $wx$ is accepted by a CFG, and we know that $x$ is accepted ...
formal languages context free closure properties
1
Closure of CFL against right-quotient with regular languages -- (formal languages context free closure properties) <blockquote>&#xA; <p>Let $A/B$ = $\{ w \mid wx \in A$ for some $x \in B \}$. Show that if A is context free and B is regular, then $A/B$ is context free.</p>&#xA;</blockquote>&#xA;&#xA;<p>My interpretati...
habedi/stack-exchange-dataset
20,100
What are the difference between and consequences of using type parameters and type indexes?
<p>In type theories, like Coq's, we can define a type with parameters, like this:</p>&#xA;&#xA;<pre><code>Inductive ListP (Element : Type) : Type&#xA; := NilP : ListP Element&#xA; | ConsP : Element -&gt; ListP Element -&gt; ListP Element.&#xA;</code></pre>&#xA;&#xA;<p>Alternatively, we can define a type with an ind...
type theory dependent types
1
What are the difference between and consequences of using type parameters and type indexes? -- (type theory dependent types) <p>In type theories, like Coq's, we can define a type with parameters, like this:</p>&#xA;&#xA;<pre><code>Inductive ListP (Element : Type) : Type&#xA; := NilP : ListP Element&#xA; | ConsP : E...
habedi/stack-exchange-dataset
20,105
Compute minimum hamming distance of a code
<p>How do you find the minimum hamming distance of a code?<br>&#xA;A naive way is computing the distance of each pair of codewords in our code. </p>&#xA;&#xA;<p>It becomes hard when the code is sufficiently large. Is there a formula for minimum hamming distance? </p>&#xA;
string metrics coding theory
1
Compute minimum hamming distance of a code -- (string metrics coding theory) <p>How do you find the minimum hamming distance of a code?<br>&#xA;A naive way is computing the distance of each pair of codewords in our code. </p>&#xA;&#xA;<p>It becomes hard when the code is sufficiently large. Is there a formula for minim...
habedi/stack-exchange-dataset
20,109
Why is the halting problem unsolvable by a turing machine?
<p>So my knowledge of CS is amateurish at best but to me, logically, it seems like the halting problem is solvable.</p>&#xA;&#xA;<p>So any human can determine if a problem halts with rigorous inspection, so why can't a very advanced, say human AI, solve the halting problem?</p>&#xA;&#xA;<p>Also, is there a machine, say...
computability halting problem
1
Why is the halting problem unsolvable by a turing machine? -- (computability halting problem) <p>So my knowledge of CS is amateurish at best but to me, logically, it seems like the halting problem is solvable.</p>&#xA;&#xA;<p>So any human can determine if a problem halts with rigorous inspection, so why can't a very ad...
habedi/stack-exchange-dataset
20,114
How many sequences in a prefix code can be compressed by m bits?
<p>I have a little understanding problem with Appendix A ("Universal Codes") in the paper "Shannon Information and Kolmogorov complexity" by Gründwald and Vitanyi (<a href="http://arxiv.org/pdf/cs/0410002.pdf" rel="nofollow">Link</a>). </p>&#xA;&#xA;<p>At the end of page 50, they say something corresponding to: </p>&...
coding theory
1
How many sequences in a prefix code can be compressed by m bits? -- (coding theory) <p>I have a little understanding problem with Appendix A ("Universal Codes") in the paper "Shannon Information and Kolmogorov complexity" by Gründwald and Vitanyi (<a href="http://arxiv.org/pdf/cs/0410002.pdf" rel="nofollow">Link</a>). ...
habedi/stack-exchange-dataset
20,117
What's an example of an unsatisfiable 3-CNF formula?
<p>I'm trying to wrap my head around an NP-completeness proof which seem to revolve around SAT/3CNF-SAT.</p>&#xA;&#xA;<p>Maybe it's the late hour but I'm afraid I can't think of a 3CNF formula that cannot be satisfied (I'm probably missing something obvious).</p>&#xA;&#xA;<p>Can you give me an example for such formula?...
logic satisfiability 3 sat
1
What's an example of an unsatisfiable 3-CNF formula? -- (logic satisfiability 3 sat) <p>I'm trying to wrap my head around an NP-completeness proof which seem to revolve around SAT/3CNF-SAT.</p>&#xA;&#xA;<p>Maybe it's the late hour but I'm afraid I can't think of a 3CNF formula that cannot be satisfied (I'm probably mis...
habedi/stack-exchange-dataset
20,119
Why can any polynomial and exponential be represented as a recurrence?
<p>I posted <a href="https://math.stackexchange.com/questions/654458/recurrence-relation-for-polynomial-and-exponential">this question on math.SE</a> but I haven't got any reply so I'm posting here also.</p>&#xA;&#xA;<p>I am reading The Algorithm Design Manual by Steven S Skiena.</p>&#xA;&#xA;<p>In Section 4.10.1 Recur...
recurrence relation discrete mathematics
1
Why can any polynomial and exponential be represented as a recurrence? -- (recurrence relation discrete mathematics) <p>I posted <a href="https://math.stackexchange.com/questions/654458/recurrence-relation-for-polynomial-and-exponential">this question on math.SE</a> but I haven't got any reply so I'm posting here also....
habedi/stack-exchange-dataset
20,126
A heuristic for finding a maximum disjoint set
<p><strong>Background</strong></p>&#xA;&#xA;<p>I need to find a largest set of non-overlapping axis-parallel squares, out of a given collection of candidate squares.</p>&#xA;&#xA;<p>This problem is NP-complete. Many papers suggest approximation algorithms (see <a href="https://en.wikipedia.org/wiki/Maximum_disjoint_set...
algorithms computational geometry efficiency heuristics
1
A heuristic for finding a maximum disjoint set -- (algorithms computational geometry efficiency heuristics) <p><strong>Background</strong></p>&#xA;&#xA;<p>I need to find a largest set of non-overlapping axis-parallel squares, out of a given collection of candidate squares.</p>&#xA;&#xA;<p>This problem is NP-complete. M...
habedi/stack-exchange-dataset
20,127
Reducing 3CNF to Clique: Why do we omit negated literals?
<p>I have an example for a reduction of 3CNF to Clique, there is one thing I don't get about it, hopefully you could clarify it. The reduction works like this:</p>&#xA;&#xA;<blockquote>&#xA; <p>Construct a graph G = (V, E) as follows:</p>&#xA; &#xA; <p>Vertices: Each literal corresponds to a vertex.</p>&#xA; &#xA;...
complexity theory np complete reductions
1
Reducing 3CNF to Clique: Why do we omit negated literals? -- (complexity theory np complete reductions) <p>I have an example for a reduction of 3CNF to Clique, there is one thing I don't get about it, hopefully you could clarify it. The reduction works like this:</p>&#xA;&#xA;<blockquote>&#xA; <p>Construct a graph G ...
habedi/stack-exchange-dataset
20,131
Deadlock and cycle in a resource allocation graph
<p><img src="https://i.stack.imgur.com/bamMN.png" alt="enter image description here"></p>&#xA;&#xA;<p>Here is a resource allocation graph asked in my Operating Systems Theory midterm. The question is, "Is there a deadlock here? Explain your answer in detail"</p>&#xA;&#xA;<p>Ra and Rb are resource sets and every dot ins...
operating systems concurrency resource allocation deadlocks
1
Deadlock and cycle in a resource allocation graph -- (operating systems concurrency resource allocation deadlocks) <p><img src="https://i.stack.imgur.com/bamMN.png" alt="enter image description here"></p>&#xA;&#xA;<p>Here is a resource allocation graph asked in my Operating Systems Theory midterm. The question is, "Is ...
habedi/stack-exchange-dataset
20,143
Why does this automation accept the empty string?
<p>I am new to Automata Theory. I am studying the book thoroughly and understanding it well. I have got a confusion regarding NFA. Why does this automaton accept the empty string λ?</p>&#xA;&#xA;<p><img src="https://i.stack.imgur.com/BV2Eh.jpg" alt="NFA"></p>&#xA;&#xA;<p>What I think is that: implicitly δ(q,λ)=q for al...
automata finite automata
1
Why does this automation accept the empty string? -- (automata finite automata) <p>I am new to Automata Theory. I am studying the book thoroughly and understanding it well. I have got a confusion regarding NFA. Why does this automaton accept the empty string λ?</p>&#xA;&#xA;<p><img src="https://i.stack.imgur.com/BV2Eh....
habedi/stack-exchange-dataset
20,152
Genetic algorithm: What is the expected number of strings that are explored?
<p>My question concerns genetic algorithm searching along bit strings.</p>&#xA;&#xA;<p>Given:</p>&#xA;&#xA;<ul>&#xA;<li>$N$ = population size</li>&#xA;<li>$l$ = length of bit strings</li>&#xA;<li>$p_c$ = probability that a single crossover occur (double crossover never occur)</li>&#xA;<li>$p_m$ = probability for a give...
algorithms optimization average case genetic algorithms
1
Genetic algorithm: What is the expected number of strings that are explored? -- (algorithms optimization average case genetic algorithms) <p>My question concerns genetic algorithm searching along bit strings.</p>&#xA;&#xA;<p>Given:</p>&#xA;&#xA;<ul>&#xA;<li>$N$ = population size</li>&#xA;<li>$l$ = length of bit strings...
habedi/stack-exchange-dataset
20,156
Compressing normally distributed data
<p>Given normally distributed integers with a mean of 0 and a standard deviation $\sigma$ around 1000, how do I compress those numbers (almost) perfectly? Given the entropy of the Gaussian distribution, it should be possible to store any value $x$ using $$\frac{1}{2} \mathrm{log}_2(2\pi\sigma^2)+\frac{x^2}{2\sigma^2}\...
information theory randomness data compression entropy
1
Compressing normally distributed data -- (information theory randomness data compression entropy) <p>Given normally distributed integers with a mean of 0 and a standard deviation $\sigma$ around 1000, how do I compress those numbers (almost) perfectly? Given the entropy of the Gaussian distribution, it should be possi...
habedi/stack-exchange-dataset
20,167
How to show that all 2-terminal SP-graphs are O(log n)-outer-planar
<p>I am trying to show that every 2-terminal SP-graph is $O(\log(n))$-outer-planar for a challenge question on my assignment. In particular, I am trying to prove this by induction on the number of combinations (either a series or a parallel combination). This is what I have so far.</p>&#xA;&#xA;<p>The base case on $0$ ...
graphs
1
How to show that all 2-terminal SP-graphs are O(log n)-outer-planar -- (graphs) <p>I am trying to show that every 2-terminal SP-graph is $O(\log(n))$-outer-planar for a challenge question on my assignment. In particular, I am trying to prove this by induction on the number of combinations (either a series or a parallel...
habedi/stack-exchange-dataset
20,181
Indentation based Grammars
<p>Considering programming languages with significant whitespace for indentation, such as Python or Haskell. How does this whitespace fit into the grand schemes of programming language grammars.</p>&#xA;&#xA;<p>I can see that a "preprocessor" can convert indent changes into tokens which are then handled in grammars, ye...
formal grammars compilers parsers
1
Indentation based Grammars -- (formal grammars compilers parsers) <p>Considering programming languages with significant whitespace for indentation, such as Python or Haskell. How does this whitespace fit into the grand schemes of programming language grammars.</p>&#xA;&#xA;<p>I can see that a "preprocessor" can convert...
habedi/stack-exchange-dataset
20,185
Solving the part-of-speech tagging problem with HMM
<p>There is a famous <a href="http://en.wikipedia.org/wiki/Part-of-speech_tagging" rel="nofollow">part-of-speech tagging problem</a> in Natural Language Processing. The popular solution is to use <a href="http://en.wikipedia.org/wiki/Hidden_Markov_model" rel="nofollow">Hidden Markov Models</a>.</p>&#xA;&#xA;<p>So that,...
machine learning natural language processing hidden markov models
1
Solving the part-of-speech tagging problem with HMM -- (machine learning natural language processing hidden markov models) <p>There is a famous <a href="http://en.wikipedia.org/wiki/Part-of-speech_tagging" rel="nofollow">part-of-speech tagging problem</a> in Natural Language Processing. The popular solution is to use <...
habedi/stack-exchange-dataset
20,189
How do GPUs compute sines?
<p>I've been wondering lately how GPUs compute sines and cosines, and Google hasn't helped me finding a precise answer.</p>&#xA;&#xA;<p>Initially, I was thinking that in order to make the computations as fast as possible, the GPU would use some kind of lookup table. But then I realized, storing all sin values in a tabl...
approximation arithmetic
1
How do GPUs compute sines? -- (approximation arithmetic) <p>I've been wondering lately how GPUs compute sines and cosines, and Google hasn't helped me finding a precise answer.</p>&#xA;&#xA;<p>Initially, I was thinking that in order to make the computations as fast as possible, the GPU would use some kind of lookup tab...
habedi/stack-exchange-dataset
20,191
Computation tree logic and Kripke structures
<p>Specifications in <a href="http://en.wikipedia.org/wiki/Kripke_structure_%28model_checking%29" rel="nofollow">Kripke structures</a> are verified by Computation tree logic (CTL). However, refering to <a href="http://en.wikipedia.org/wiki/Computation_tree_logic" rel="nofollow">this Wikipedia article</a> the CTL-operat...
logic model checking temporal logic computation tree logic
1
Computation tree logic and Kripke structures -- (logic model checking temporal logic computation tree logic) <p>Specifications in <a href="http://en.wikipedia.org/wiki/Kripke_structure_%28model_checking%29" rel="nofollow">Kripke structures</a> are verified by Computation tree logic (CTL). However, refering to <a href="...
habedi/stack-exchange-dataset
20,197
Until quantifier of Computation Tree Logic
<p>It's quite a short question: Refering to <a href="http://en.wikipedia.org/wiki/Computation_tree_logic" rel="nofollow">this Wikipedia article</a> <code>p U q</code> means, that <em><code>p</code> has to hold at least until at some point <code>q</code> holds</em>.</p>&#xA;&#xA;<p>So, does it mean:</p>&#xA;&#xA;<ol>&#x...
terminology logic temporal logic
1
Until quantifier of Computation Tree Logic -- (terminology logic temporal logic) <p>It's quite a short question: Refering to <a href="http://en.wikipedia.org/wiki/Computation_tree_logic" rel="nofollow">this Wikipedia article</a> <code>p U q</code> means, that <em><code>p</code> has to hold at least until at some point ...
habedi/stack-exchange-dataset
20,204
Has it been proven that the optimization TSP is (or is not) polynomial-time verifiable if P ≠ NP?
<p>The optimization version of TSP asks for the length of the shortest tour. Unlike the decision version of TSP, there's no obvious way to verify a proposed solution of the optimization problem in polynomial time. But is there a proof of whether or not it can be verified in polynomial time assuming P ≠ NP?</p>&#xA;
complexity theory optimization np traveling salesman
1
Has it been proven that the optimization TSP is (or is not) polynomial-time verifiable if P ≠ NP? -- (complexity theory optimization np traveling salesman) <p>The optimization version of TSP asks for the length of the shortest tour. Unlike the decision version of TSP, there's no obvious way to verify a proposed solutio...
habedi/stack-exchange-dataset
20,207
How to convert a Turing Machine program to a tiling using Wang Tiles?
<p><sup>This is a cross-post from a post on <a href="https://math.stackexchange.com/posts/655746/edit">MathSE</a> due to lack of answers.</sup></p>&#xA;&#xA;<p>To illustrate my question I provide the following example.</p>&#xA;&#xA;<p>The website <a href="http://db.ing.puc.cl/turingmachine/" rel="nofollow noreferrer">O...
turing machines simulation computation models tiling
1
How to convert a Turing Machine program to a tiling using Wang Tiles? -- (turing machines simulation computation models tiling) <p><sup>This is a cross-post from a post on <a href="https://math.stackexchange.com/posts/655746/edit">MathSE</a> due to lack of answers.</sup></p>&#xA;&#xA;<p>To illustrate my question I prov...
habedi/stack-exchange-dataset
20,212
Glue-concatenation v.s concatenation
<p>I wanted to give the following as a homework question, but my first few attempts to solve it failed, so now I'm just curios for a solution:</p>&#xA;&#xA;<p>For two words $x,y\in \Sigma^*$ and for a letter $\sigma\in \Sigma$ we define the <em>glue-concatenation</em> of $x\sigma$ and $\sigma y$ to be $g(x\sigma,\sigma...
formal languages
1
Glue-concatenation v.s concatenation -- (formal languages) <p>I wanted to give the following as a homework question, but my first few attempts to solve it failed, so now I'm just curios for a solution:</p>&#xA;&#xA;<p>For two words $x,y\in \Sigma^*$ and for a letter $\sigma\in \Sigma$ we define the <em>glue-concatenati...
habedi/stack-exchange-dataset
20,220
Starvation in longest remaining time first CPU scheduling
<p>I want to know if longest remaining time first (LRTF) CPU scheduling has starvation or not. Also give reason how it starve/does not starve a process.</p>&#xA;&#xA;<p>I know longest job first (LJF) may starve a process if all other incoming processes have longer CPU burst.</p>&#xA;
operating systems
1
Starvation in longest remaining time first CPU scheduling -- (operating systems) <p>I want to know if longest remaining time first (LRTF) CPU scheduling has starvation or not. Also give reason how it starve/does not starve a process.</p>&#xA;&#xA;<p>I know longest job first (LJF) may starve a process if all other incom...
habedi/stack-exchange-dataset
20,224
When does the IEEE-754 64-bit float break as a counter
<p>As a matter of curiosity I've been trying to determine at what point a 64-bit float no longer reflects the addition of 1 as expected; that is, at what point the digits as printed do not correspond to the digits of a 64-bit integer that is incremented in sync.</p>&#xA;&#xA;<p>Around 1e15 I can continually add 1 or su...
floating point counting
1
When does the IEEE-754 64-bit float break as a counter -- (floating point counting) <p>As a matter of curiosity I've been trying to determine at what point a 64-bit float no longer reflects the addition of 1 as expected; that is, at what point the digits as printed do not correspond to the digits of a 64-bit integer th...
habedi/stack-exchange-dataset
20,235
Difference between 1* + 0* and (1 + 0)*
<p>I know that <code>(1 + 0)*</code> is the set of all bit strings; but isn't <code>1* + 0*</code> the same thing?</p>&#xA;
formal languages terminology regular languages regular expressions
1
Difference between 1* + 0* and (1 + 0)* -- (formal languages terminology regular languages regular expressions) <p>I know that <code>(1 + 0)*</code> is the set of all bit strings; but isn't <code>1* + 0*</code> the same thing?</p>&#xA;
habedi/stack-exchange-dataset
20,239
Precedence in regular expressions
<p>I'm having trouble finding the language represented by the following:</p>&#xA;&#xA;<p>(AA|BB)*</p>&#xA;&#xA;<p>Should the expression be read as... ( A (A|B) B ) *&#xA;or... ( (AA) | (BB) )*</p>&#xA;&#xA;<p>If that isn't clear, should this produce something like... ABABAB or should it produce AABBAABBBBAA</p>&#xA;&#x...
formal languages terminology regular expressions
1
Precedence in regular expressions -- (formal languages terminology regular expressions) <p>I'm having trouble finding the language represented by the following:</p>&#xA;&#xA;<p>(AA|BB)*</p>&#xA;&#xA;<p>Should the expression be read as... ( A (A|B) B ) *&#xA;or... ( (AA) | (BB) )*</p>&#xA;&#xA;<p>If that isn't clear, sh...
habedi/stack-exchange-dataset
20,245
Which computational model is used to analyse the runtime of matrix multiplication algorithms?
<p>Although I have already learned something about the asymptotic runtimes of matrix multiplication algorithms (Strassen's algorithm and similar things), I have never found any explicit and satisfactory reference to a model of computation, which is used to measure this complexity. In fact, I have found three possible a...
algorithm analysis runtime analysis matrices machine models
1
Which computational model is used to analyse the runtime of matrix multiplication algorithms? -- (algorithm analysis runtime analysis matrices machine models) <p>Although I have already learned something about the asymptotic runtimes of matrix multiplication algorithms (Strassen's algorithm and similar things), I have ...
habedi/stack-exchange-dataset
20,249
Is $a^{n+m}b^{n}c^{m}$ context free?
<p>Language:</p>&#xA;&#xA;<p>$ L = a^{n+m}b^{n}c^{m} $</p>&#xA;&#xA;<p>As per a recent test I gave, this language is not context free.</p>&#xA;&#xA;<p>However, I think it is.</p>&#xA;&#xA;<p><strong>Corresponding Grammar:</strong></p>&#xA;&#xA;<p>$ X \rightarrow aXY \space |\space \epsilon $</p>&#xA;&#xA;<p>$ Y \righta...
formal languages context free formal grammars
1
Is $a^{n+m}b^{n}c^{m}$ context free? -- (formal languages context free formal grammars) <p>Language:</p>&#xA;&#xA;<p>$ L = a^{n+m}b^{n}c^{m} $</p>&#xA;&#xA;<p>As per a recent test I gave, this language is not context free.</p>&#xA;&#xA;<p>However, I think it is.</p>&#xA;&#xA;<p><strong>Corresponding Grammar:</strong></...
habedi/stack-exchange-dataset
20,256
Counterexample that B-A can be NOT context free
<p>Given that <code>A</code> is a context free language and <code>B</code> is a regular language, <code>B-A</code> can be not context free as it is equal to <code>B ∩ A'</code>, and context free languages are not closed under complement. Could you give me a counterexample? </p>&#xA;
formal languages
1
Counterexample that B-A can be NOT context free -- (formal languages) <p>Given that <code>A</code> is a context free language and <code>B</code> is a regular language, <code>B-A</code> can be not context free as it is equal to <code>B ∩ A'</code>, and context free languages are not closed under complement. Could you gi...
habedi/stack-exchange-dataset
21,280
Does "standard" Dijkstra's algorithm work with bi-directional edges and zero cost edges?
<p>I have been reading about Dijkstra's algorithm and I think I understand it. I followed the algorithm in pseudo-code from Wikipedia, and now I wonder:</p>&#xA;&#xA;<ol>&#xA;<li><p>If my graph is bi-directional and I add each edge to my graph <em>twice</em> (once "forwards", once "backwards"), will the "standard" Dijk...
algorithms graphs shortest path
1
Does "standard" Dijkstra's algorithm work with bi-directional edges and zero cost edges? -- (algorithms graphs shortest path) <p>I have been reading about Dijkstra's algorithm and I think I understand it. I followed the algorithm in pseudo-code from Wikipedia, and now I wonder:</p>&#xA;&#xA;<ol>&#xA;<li><p>If my graph ...
habedi/stack-exchange-dataset
21,283
Why is the PageRank vector also the eigenvector of the web adjacency matrix?
<p>From <a href="http://en.wikipedia.org/wiki/PageRank#Damping_factor" rel="nofollow">wikipedia</a>:</p>&#xA;&#xA;<blockquote>&#xA; <p>The PageRank values are the entries of the dominant eigenvector of the&#xA; modified adjacency matrix. This makes PageRank a particularly elegant&#xA; metric</p>&#xA;</blockquote>&#x...
graphs search algorithms
1
Why is the PageRank vector also the eigenvector of the web adjacency matrix? -- (graphs search algorithms) <p>From <a href="http://en.wikipedia.org/wiki/PageRank#Damping_factor" rel="nofollow">wikipedia</a>:</p>&#xA;&#xA;<blockquote>&#xA; <p>The PageRank values are the entries of the dominant eigenvector of the&#xA; ...
habedi/stack-exchange-dataset
21,284
Why is the class of recursively enumerable languages not closed under complementation?
<p>I am having a hard time understanding closure properties of recrusively enumerable languages. I have read the explanation on <a href="http://www.eecs.wsu.edu/~cook/tcs/l19.html" rel="nofollow">this site</a> but still unable to fully understand why they are not closed under complementation?</p>&#xA;&#xA;<p>Explanatio...
computability closure properties semi decidability
1
Why is the class of recursively enumerable languages not closed under complementation? -- (computability closure properties semi decidability) <p>I am having a hard time understanding closure properties of recrusively enumerable languages. I have read the explanation on <a href="http://www.eecs.wsu.edu/~cook/tcs/l19.ht...
habedi/stack-exchange-dataset
21,294
Sequential numbers to unique-looking numbers
<p>I'm not sure how to word this because I'm not familiar with this, but I'm sure a process like this is rather common.</p>&#xA;&#xA;<p>Basically, I've got members signing up for our website, and each one is assigned a normal sequential ID (a MySQL auto_increment ID), i.e. <code>1</code>, <code>2</code>, <code>3</code>...
hash
1
Sequential numbers to unique-looking numbers -- (hash) <p>I'm not sure how to word this because I'm not familiar with this, but I'm sure a process like this is rather common.</p>&#xA;&#xA;<p>Basically, I've got members signing up for our website, and each one is assigned a normal sequential ID (a MySQL auto_increment I...
habedi/stack-exchange-dataset
21,298
How to prove any polynomial of degree $k$ is in $\Theta(n^k)$?
<p>I want to prove that any polynomial of degree $k$ is in $\Theta(n^k)$. The coefficient of $n^k$, $a_{k}$, is positive.</p>&#xA;&#xA;<p>I know I need $0 \leq c_{1}n^k \leq a_{k}n^k + ... + a_{0} \leq c_{2}n^k$ for all $n \geq n_0$.</p>&#xA;&#xA;<p>The upper limit is easy to prove by taking $c_{2} = \sum\limits_{i=0}^...
asymptotics
1
How to prove any polynomial of degree $k$ is in $\Theta(n^k)$? -- (asymptotics) <p>I want to prove that any polynomial of degree $k$ is in $\Theta(n^k)$. The coefficient of $n^k$, $a_{k}$, is positive.</p>&#xA;&#xA;<p>I know I need $0 \leq c_{1}n^k \leq a_{k}n^k + ... + a_{0} \leq c_{2}n^k$ for all $n \geq n_0$.</p>&#x...
habedi/stack-exchange-dataset
21,301
Proving that {0^{2^k}} is not regular with the Myhill-Nerode theorem
<p>My language is the repetition of 0 to a length that's a power of 2:</p>&#xA;&#xA;<p>$L = \{ 0^k \ni k=2^n, n \geq 1 \}$</p>&#xA;&#xA;<p>I want to know how to prove that this language is not regular. I have attempted the proof below, but think it may be incorrect due to my potentially wrong assumption that the Myhill...
formal languages regular languages
1
Proving that {0^{2^k}} is not regular with the Myhill-Nerode theorem -- (formal languages regular languages) <p>My language is the repetition of 0 to a length that's a power of 2:</p>&#xA;&#xA;<p>$L = \{ 0^k \ni k=2^n, n \geq 1 \}$</p>&#xA;&#xA;<p>I want to know how to prove that this language is not regular. I have at...
habedi/stack-exchange-dataset
21,309
How to find a Deterministic PDA for an intersection of languages
<p>There are two languages,</p>&#xA;&#xA;<p>$\qquad L_1 = \{w\in\{a,b\}^*: N_a\leq N_b\}$ and<br>&#xA;$\qquad L_2=\{w\in\{a,b\}^*: N_b\leq 2N_a\}$ </p>&#xA;&#xA;<p>where $N_a$ means the number of occurrences of $a$ in the string $w$. Same for $N_b$.</p>&#xA;&#xA;<p>I've proved that $L_1$ has a DPDA (hope this is right)...
formal languages context free automata pushdown automata
1
How to find a Deterministic PDA for an intersection of languages -- (formal languages context free automata pushdown automata) <p>There are two languages,</p>&#xA;&#xA;<p>$\qquad L_1 = \{w\in\{a,b\}^*: N_a\leq N_b\}$ and<br>&#xA;$\qquad L_2=\{w\in\{a,b\}^*: N_b\leq 2N_a\}$ </p>&#xA;&#xA;<p>where $N_a$ means the number ...
habedi/stack-exchange-dataset
21,311
Runtime analysis of a recursive algorithm with a tricky amount of work per recursive call
<p>I want to analyze the runtime of this algorithm:</p>&#xA;&#xA;<pre><code>int fun (int arr[], int n) {&#xA; int result = 1;&#xA; int i, j;&#xA;&#xA; if (n == 1)&#xA; return 1;&#xA;&#xA; else {&#xA; result = fun(arr, 2n/3);&#xA; for (i = 1; i &lt;= sqrt(n); i=i*2);&#xA; ...
algorithm analysis runtime analysis recurrence relation
1
Runtime analysis of a recursive algorithm with a tricky amount of work per recursive call -- (algorithm analysis runtime analysis recurrence relation) <p>I want to analyze the runtime of this algorithm:</p>&#xA;&#xA;<pre><code>int fun (int arr[], int n) {&#xA; int result = 1;&#xA; int i, j;&#xA;&#xA; if (n == ...
habedi/stack-exchange-dataset
21,318
Why we need to read memory on a write-miss?
<p>I noticed that in write-back caches, when the cpu wants to write to a block, it fetches the block from memory and then updates it. If the block is going to be overwritten and changed by processor, why does the cpu need to read that block from memory?</p>&#xA;
cpu cache
1
Why we need to read memory on a write-miss? -- (cpu cache) <p>I noticed that in write-back caches, when the cpu wants to write to a block, it fetches the block from memory and then updates it. If the block is going to be overwritten and changed by processor, why does the cpu need to read that block from memory?</p>&#xA...
habedi/stack-exchange-dataset
21,324
Sliding window protocol, calculation of sequence number bits
<p>I am preparing for my exams and was solving problems regarding <code>Sliding Window Protocol</code> and I came across these questions..</p>&#xA;&#xA;<blockquote>&#xA; <p>A 1000km long cable operates a 1MBPS. Propagation delay is 10 microsec/km. If frame size is 1kB, then how many bits are required for sequence numb...
computer networks
1
Sliding window protocol, calculation of sequence number bits -- (computer networks) <p>I am preparing for my exams and was solving problems regarding <code>Sliding Window Protocol</code> and I came across these questions..</p>&#xA;&#xA;<blockquote>&#xA; <p>A 1000km long cable operates a 1MBPS. Propagation delay is 10 ...
habedi/stack-exchange-dataset
21,342
Blum's speedup theorem in big-O format?
<p>Is there a way to state <a href="http://en.wikipedia.org/wiki/Blum%27s_speedup_theorem" rel="nofollow">Blum's speedup theorem</a> in terms of <a href="http://en.wikipedia.org/wiki/Landau_notation" rel="nofollow">Big-O (Landau) notation</a>?</p>&#xA;
complexity theory asymptotics
1
Blum's speedup theorem in big-O format? -- (complexity theory asymptotics) <p>Is there a way to state <a href="http://en.wikipedia.org/wiki/Blum%27s_speedup_theorem" rel="nofollow">Blum's speedup theorem</a> in terms of <a href="http://en.wikipedia.org/wiki/Landau_notation" rel="nofollow">Big-O (Landau) notation</a>?</...
habedi/stack-exchange-dataset
21,359
Can reversing the final and non-final states of a DFA produce the complement of the original language?
<p>Is this true? If I change all final states of a given Deterministic Finite Automata to non final states and all non final states to final states then does this new automata represent the complement of the language that was accepted by the original automata?</p>&#xA;&#xA;<p>What if we talk about a Non deterministic f...
formal languages automata finite automata
1
Can reversing the final and non-final states of a DFA produce the complement of the original language? -- (formal languages automata finite automata) <p>Is this true? If I change all final states of a given Deterministic Finite Automata to non final states and all non final states to final states then does this new aut...
habedi/stack-exchange-dataset
21,362
Hierarchical Paging memory requirements
<p>OS Book written by Galvin et all states that <em>if page size is 4KB and size of virtual space is 32 bits then 2^(32-12) page entries would be required which is too huge to store in memory!!</em> </p>&#xA;&#xA;<p>Therefore it recommends to break it down by paging the inner page table as well. Now my question is how ...
operating systems paging
1
Hierarchical Paging memory requirements -- (operating systems paging) <p>OS Book written by Galvin et all states that <em>if page size is 4KB and size of virtual space is 32 bits then 2^(32-12) page entries would be required which is too huge to store in memory!!</em> </p>&#xA;&#xA;<p>Therefore it recommends to break i...
habedi/stack-exchange-dataset
21,365
Clustered index is dense or sparse?
<p>I am confused about clustered index is dense or sparse. I searched for that, sources saying it is sparse, but can be dense also. What is it exactly?</p>&#xA;
terminology database theory
1
Clustered index is dense or sparse? -- (terminology database theory) <p>I am confused about clustered index is dense or sparse. I searched for that, sources saying it is sparse, but can be dense also. What is it exactly?</p>&#xA;
habedi/stack-exchange-dataset
21,367
A quine in pure lambda calculus
<p>I would like an example of a <a href="http://en.wikipedia.org/wiki/Quine_%28computing%29">quine</a> in pure <a href="http://en.wikipedia.org/wiki/Lambda_calculus">lambda calculus</a>. I was quite surprised that I couldn't find one by googling. <a href="http://www.nyx.net/~gthompso/quine.htm">The quine page</a> lists...
lambda calculus
1
A quine in pure lambda calculus -- (lambda calculus) <p>I would like an example of a <a href="http://en.wikipedia.org/wiki/Quine_%28computing%29">quine</a> in pure <a href="http://en.wikipedia.org/wiki/Lambda_calculus">lambda calculus</a>. I was quite surprised that I couldn't find one by googling. <a href="http://www....
habedi/stack-exchange-dataset
21,369
How to name documents in windows?
<p>What is the best way to name documents and folders in windows? Im thinging about maybe there will be some conflict in some programs? Or when searching in terminal</p>&#xA;&#xA;<p>This_Is_Best.doc</p>&#xA;&#xA;<p>ThisIsBest.doc</p>&#xA;&#xA;<p>This Is Best.doc</p>&#xA;
filesystems
1
How to name documents in windows? -- (filesystems) <p>What is the best way to name documents and folders in windows? Im thinging about maybe there will be some conflict in some programs? Or when searching in terminal</p>&#xA;&#xA;<p>This_Is_Best.doc</p>&#xA;&#xA;<p>ThisIsBest.doc</p>&#xA;&#xA;<p>This Is Best.doc</p>&#x...
habedi/stack-exchange-dataset
21,372
Help in understanding exactly how lattices used as one way functions for hashing
<p>(This question is related to homework)&#xA;I am doing a cryptography course via long distance and we have been given an assignment which is based on lattice-based cryptography. I have spent the majority of the past week sifting through papers and videos in an attempt to build my understanding of the subject, but due...
cryptography hash lattices
1
Help in understanding exactly how lattices used as one way functions for hashing -- (cryptography hash lattices) <p>(This question is related to homework)&#xA;I am doing a cryptography course via long distance and we have been given an assignment which is based on lattice-based cryptography. I have spent the majority o...
habedi/stack-exchange-dataset
21,373
Can a DFA have two symbols on one arrow?
<p>I know that a DFA has to have exactly one transition for each symbol in the alphabet, but is it allowed to have two symbols on the same arrow? If, for example, I have a DFA with states $q_0$ and $q_1$, can I have one arrow from $q_0$ to $q_1$ with both $a$ and $b$? </p>&#xA;&#xA;<p>This may be a stupid question, but...
terminology automata finite automata
1
Can a DFA have two symbols on one arrow? -- (terminology automata finite automata) <p>I know that a DFA has to have exactly one transition for each symbol in the alphabet, but is it allowed to have two symbols on the same arrow? If, for example, I have a DFA with states $q_0$ and $q_1$, can I have one arrow from $q_0$ ...
habedi/stack-exchange-dataset
21,376
Error estimates of piecewise-linear curve approximations
<p>In order to plot a curve a set of points is usually calculated based on some formula. The function FPLOT in MATLAB also supports plotting with some error tolerance. Its help says the following about this functionality:</p>&#xA;&#xA;<pre><code>The FPLOT function begins with a minimum step of size (XMAX-XMIN)*TOL.&#xA...
approximation approximation algorithms error estimation
1
Error estimates of piecewise-linear curve approximations -- (approximation approximation algorithms error estimation) <p>In order to plot a curve a set of points is usually calculated based on some formula. The function FPLOT in MATLAB also supports plotting with some error tolerance. Its help says the following about ...
habedi/stack-exchange-dataset
21,378
Which part of the computer allocates memory in RAM?
<p>When we declare a variable there will be a random part of memory will be allocated in RAM. Which component will allocate the memory? Is the processor or any other specific hardware doing the allocation?</p>&#xA;
operating systems memory management memory access memory hardware
1
Which part of the computer allocates memory in RAM? -- (operating systems memory management memory access memory hardware) <p>When we declare a variable there will be a random part of memory will be allocated in RAM. Which component will allocate the memory? Is the processor or any other specific hardware doing the all...
habedi/stack-exchange-dataset
21,381
Finding all paths with lengths in a fixed interval in sparse graphs
<p>What is the most efficient way to find all paths of length M to N in a large sparse graph?</p>&#xA;&#xA;<p>Some general information:</p>&#xA;&#xA;<ul>&#xA;<li>Graph has 30,000 to 50,000 nodes</li>&#xA;<li>Average number of edges per node ~ 10</li>&#xA;<li>M=4, N=7</li>&#xA;<li>Graph has cycles</li>&#xA;</ul>&#xA;
algorithms graphs shortest path
1
Finding all paths with lengths in a fixed interval in sparse graphs -- (algorithms graphs shortest path) <p>What is the most efficient way to find all paths of length M to N in a large sparse graph?</p>&#xA;&#xA;<p>Some general information:</p>&#xA;&#xA;<ul>&#xA;<li>Graph has 30,000 to 50,000 nodes</li>&#xA;<li>Average...
habedi/stack-exchange-dataset
21,383
Decidability of fullness of intersection of a CSL with a regular language
<p>Let $L_r$ be a regular language with alphabet $\Sigma$ and $L_{\text{csl}}$ be a context sensitive language. Are any of the following questions decidable?</p>&#xA;&#xA;<ol>&#xA;<li>$L_r \cap L_\text{csl} \stackrel{?}{=} L_r$</li>&#xA;<li>$\Sigma^* \cap L_\text{csl} \stackrel{?}{=} L_r$</li>&#xA;<li>$L_r \cap L_\text...
formal languages computability undecidability
1
Decidability of fullness of intersection of a CSL with a regular language -- (formal languages computability undecidability) <p>Let $L_r$ be a regular language with alphabet $\Sigma$ and $L_{\text{csl}}$ be a context sensitive language. Are any of the following questions decidable?</p>&#xA;&#xA;<ol>&#xA;<li>$L_r \cap L...
habedi/stack-exchange-dataset
21,386
Understanding expected time bound for unsuccessful search in R-way tries
<p>As per <a href="http://algs4.cs.princeton.edu/lectures/52Tries.pdf" rel="nofollow">Tries slides</a> (page 17) from Algorithm 4th edition book by Robert Sedgewick, the asymptotic expected runtime for an unsuccessful search in $R$-way tries miss is $O(\log_R N)$. Can someone please explain how this number can be deriv...
data structures runtime analysis search trees
1
Understanding expected time bound for unsuccessful search in R-way tries -- (data structures runtime analysis search trees) <p>As per <a href="http://algs4.cs.princeton.edu/lectures/52Tries.pdf" rel="nofollow">Tries slides</a> (page 17) from Algorithm 4th edition book by Robert Sedgewick, the asymptotic expected runtim...
habedi/stack-exchange-dataset
21,390
Determining if a context-free grammar produces even-length strings
<p>Given a context-free grammar, is there an algorithm to determine if the CFG will ever produce an even length string? Or is this undecidable?</p>&#xA;
computability context free formal grammars undecidability
1
Determining if a context-free grammar produces even-length strings -- (computability context free formal grammars undecidability) <p>Given a context-free grammar, is there an algorithm to determine if the CFG will ever produce an even length string? Or is this undecidable?</p>&#xA;
habedi/stack-exchange-dataset
21,397
Is there a designation for this not-quite-exponential time?
<p>I've been working and experimenting with an algorithm that <em>may</em> take time $O^*(2^\sqrt{n})$. Here $O^*(f(n))$ simply neglects all polynomial terms. I've seen <a href="http://www.scottaaronson.com/blog/?p=394#comment-13888" rel="nofollow">a comment on Scott Aaronson's blog</a> that mentions graph isomorphis...
terminology landau notation
1
Is there a designation for this not-quite-exponential time? -- (terminology landau notation) <p>I've been working and experimenting with an algorithm that <em>may</em> take time $O^*(2^\sqrt{n})$. Here $O^*(f(n))$ simply neglects all polynomial terms. I've seen <a href="http://www.scottaaronson.com/blog/?p=394#commen...
habedi/stack-exchange-dataset
21,398
What's a trivial property?
<p>I have to show a property P is trivial.</p>&#xA;&#xA;<p>This problem has to do with Rice's Theorem, which I do not completely understand. Can someone explain the difference between trivial and non-trivial properties?</p>&#xA;
terminology computability rice theorem
1
What's a trivial property? -- (terminology computability rice theorem) <p>I have to show a property P is trivial.</p>&#xA;&#xA;<p>This problem has to do with Rice's Theorem, which I do not completely understand. Can someone explain the difference between trivial and non-trivial properties?</p>&#xA;
habedi/stack-exchange-dataset
21,400
Reduction to complement of Accept Problem
<p>I am reducing a given Turing Machine to the complement of the known undecidable problem, &#xA;$$ Complement(A_{TM}) = \{ \langle M,w \rangle \mid M \text{ is TM}, w \not\in L(M) \}$$</p>&#xA;&#xA;<p>To this Turing Machine, known as SPARSE TM:&#xA;$$&#xA;SPARSE_{TM} = \{ \langle M \rangle \mid M \text{ is 1-tape TM}...
computability turing machines reductions undecidability
1
Reduction to complement of Accept Problem -- (computability turing machines reductions undecidability) <p>I am reducing a given Turing Machine to the complement of the known undecidable problem, &#xA;$$ Complement(A_{TM}) = \{ \langle M,w \rangle \mid M \text{ is TM}, w \not\in L(M) \}$$</p>&#xA;&#xA;<p>To this Turing...
habedi/stack-exchange-dataset
21,403
Are expert systems outdated, what are better alternatives to them, if any?
<p>I need to link facts to actions through rules. If a person bought soup 10 times and he is coming at midday every day, then the system should link the fact that the person bought soup so many times, using the rule "person, consecutively buying soup 5 or more times within a month is going to buy soup with 90% confiden...
machine learning artificial intelligence
1
Are expert systems outdated, what are better alternatives to them, if any? -- (machine learning artificial intelligence) <p>I need to link facts to actions through rules. If a person bought soup 10 times and he is coming at midday every day, then the system should link the fact that the person bought soup so many times...
habedi/stack-exchange-dataset
21,405
Proving iff statement with reductions
<p>I have a statement I am trying to prove, and I'm very close, but I think I'm missing a couple of key concepts about regular and context-free languages.</p>&#xA;&#xA;<p><strong>Question:</strong> Let&#xA;$&#xA;A = \{ ww \ | \ w \ \epsilon \ \Sigma^{*} \}&#xA;$.</p>&#xA;&#xA;<p>Show that any language $L$ is Turing-dec...
turing machines reductions
1
Proving iff statement with reductions -- (turing machines reductions) <p>I have a statement I am trying to prove, and I'm very close, but I think I'm missing a couple of key concepts about regular and context-free languages.</p>&#xA;&#xA;<p><strong>Question:</strong> Let&#xA;$&#xA;A = \{ ww \ | \ w \ \epsilon \ \Sigma^...
habedi/stack-exchange-dataset
21,406
In Probabilistic Graphical Models, are Cliques and Clusters the same?
<p>I am learning Probabilistic Graphical Models with the help of the videos on Coursera. I am in week 4 and I see cliques being mentioned often. But the graphs being discussed are cluster graphs. So are the cliques and clusters the same?</p>&#xA;
graphs terminology probability theory
1
In Probabilistic Graphical Models, are Cliques and Clusters the same? -- (graphs terminology probability theory) <p>I am learning Probabilistic Graphical Models with the help of the videos on Coursera. I am in week 4 and I see cliques being mentioned often. But the graphs being discussed are cluster graphs. So are the ...
habedi/stack-exchange-dataset
21,407
Axiomatic Semantics and Postconditions
<p>I'll preface this by saying that this IS a homework question.</p>&#xA;&#xA;<p>However, when asked about how to solve it in class, (I believe) my professor was unable to complete it.</p>&#xA;&#xA;<p>The question is: </p>&#xA;&#xA;<blockquote>&#xA; <p>Compute the weakest precondition for each of the following &#xA; ...
semantics hoare logic
1
Axiomatic Semantics and Postconditions -- (semantics hoare logic) <p>I'll preface this by saying that this IS a homework question.</p>&#xA;&#xA;<p>However, when asked about how to solve it in class, (I believe) my professor was unable to complete it.</p>&#xA;&#xA;<p>The question is: </p>&#xA;&#xA;<blockquote>&#xA; <p>...
habedi/stack-exchange-dataset
21,414
Non-Deterministic FSA to Deterministic FSA, Two initial states
<p>My method of conversion is by creating a reachable set tree and each set within the tree would represent the new states. </p>&#xA;&#xA;<p>I have never dealt with FSAs that has 2 or more initial states. How do i create my reachable set tree with two or more states? </p>&#xA;
automata finite automata
1
Non-Deterministic FSA to Deterministic FSA, Two initial states -- (automata finite automata) <p>My method of conversion is by creating a reachable set tree and each set within the tree would represent the new states. </p>&#xA;&#xA;<p>I have never dealt with FSAs that has 2 or more initial states. How do i create my rea...
habedi/stack-exchange-dataset
21,455
How can I quantify the number of swaps required for insertion sort?
<p>Based on the Wikipedia implementation of insertion sort:</p>&#xA;&#xA;<p>Given an input array $A$:</p>&#xA;&#xA;<pre><code>for i ← 1 to length(A)&#xA; j ← i&#xA; while j &gt; 0 and A[j-1] &gt; A[j]&#xA; swap A[j] and A[j-1]&#xA; j ← j - 1&#xA;</code></pre>&#xA;&#xA;<p>is there a way to quantify h...
algorithms sorting
1
How can I quantify the number of swaps required for insertion sort? -- (algorithms sorting) <p>Based on the Wikipedia implementation of insertion sort:</p>&#xA;&#xA;<p>Given an input array $A$:</p>&#xA;&#xA;<pre><code>for i ← 1 to length(A)&#xA; j ← i&#xA; while j &gt; 0 and A[j-1] &gt; A[j]&#xA; swap A[j]...
habedi/stack-exchange-dataset
21,460
Prove Queue Automaton is equivalent to Turing Machine
<p>A deterministic queue automaton (DQA) is like a PDA except the stack is replaced by a queue. A queue is a tape allowing symbols to be written (push) on the left-end and read (pull) on the right-end. </p>&#xA;&#xA;<p>Actually I've proved that a 2-tape Turing Machine can simulate the DQA. Now I'm proving the DQA can s...
turing machines automata simulation
1
Prove Queue Automaton is equivalent to Turing Machine -- (turing machines automata simulation) <p>A deterministic queue automaton (DQA) is like a PDA except the stack is replaced by a queue. A queue is a tape allowing symbols to be written (push) on the left-end and read (pull) on the right-end. </p>&#xA;&#xA;<p>Actual...
habedi/stack-exchange-dataset
21,469
What does a wedge in a graph look like?
<p>I am reading <a href="http://arxiv.org/pdf/1309.7440v2.pdf" rel="nofollow">Decompositions of Triangle-Dense Graphs</a> by Gupta et al. </p>&#xA;&#xA;<p>On page 2, in Definition 1 what is a wedge in a graph? </p>&#xA;&#xA;<p>I know what triangle is but I don't know what wedge is and google isn't helping!</p>&#xA;
graphs terminology
1
What does a wedge in a graph look like? -- (graphs terminology) <p>I am reading <a href="http://arxiv.org/pdf/1309.7440v2.pdf" rel="nofollow">Decompositions of Triangle-Dense Graphs</a> by Gupta et al. </p>&#xA;&#xA;<p>On page 2, in Definition 1 what is a wedge in a graph? </p>&#xA;&#xA;<p>I know what triangle is but I...
habedi/stack-exchange-dataset
21,481
Description of “Logistics Domain” in AI
<p>While reading some papers in AI (for a project I have to do), I see expressions "blocks world domain" and "logistics domain". I know what blocks world domain is, but I don't know the definition of logistics domain.</p>&#xA;&#xA;<p>Any help would be appreciated.</p>&#xA;
terminology artificial intelligence
1
Description of “Logistics Domain” in AI -- (terminology artificial intelligence) <p>While reading some papers in AI (for a project I have to do), I see expressions "blocks world domain" and "logistics domain". I know what blocks world domain is, but I don't know the definition of logistics domain.</p>&#xA;&#xA;<p>Any h...
habedi/stack-exchange-dataset
21,507
What is an algorithm for what I am trying to do?
<p>I have an equation $y=2x^4-20x^2-50x$ within a range of -4 to 6 </p>&#xA;&#xA;<p>I already have an algorithim that tell me the y value when I plug in the $x$. It simply uses a loop.</p>&#xA;&#xA;<p>What I am trying to do is determine what will be be the y max value and what $x$ corresponds to it.&#xA;Is there some s...
algorithms
1
What is an algorithm for what I am trying to do? -- (algorithms) <p>I have an equation $y=2x^4-20x^2-50x$ within a range of -4 to 6 </p>&#xA;&#xA;<p>I already have an algorithim that tell me the y value when I plug in the $x$. It simply uses a loop.</p>&#xA;&#xA;<p>What I am trying to do is determine what will be be th...
habedi/stack-exchange-dataset
21,509
The minimization operator is an effective operator
<p>Assume $\{f_i^{(n)}\}_{i=0}^\infty$ is a Gödel enumeration of the $\mu$-recursive functions of $n$ arguments, such that the $S^m_n$ theorem and the universal function theorem hold. Denote the set of (total and partial) functions $\{f:\mathbb N^k\to\mathbb N\&#xA;\}$ by $\mathfrak F^k$</p>&#xA;&#xA;<p><strong>Definit...
computability recursion mu calculus
1
The minimization operator is an effective operator -- (computability recursion mu calculus) <p>Assume $\{f_i^{(n)}\}_{i=0}^\infty$ is a Gödel enumeration of the $\mu$-recursive functions of $n$ arguments, such that the $S^m_n$ theorem and the universal function theorem hold. Denote the set of (total and partial) functi...
habedi/stack-exchange-dataset
21,510
Is this path finding problem in a 01-matrix NP-complete?
<blockquote>&#xA;<p><strong>The problem:</strong></p>&#xA;<p><em>Input</em>: An <span class="math-container">$n \times n$</span> matrix of 0's and 1's, and a position <em>pos</em> of this matrix (i.e. a pair of integers <span class="math-container">$i,j$</span> with <span class="math-container">$1 \leq i,j \leq n$</spa...
complexity theory np complete reductions np
1
Is this path finding problem in a 01-matrix NP-complete? -- (complexity theory np complete reductions np) <blockquote>&#xA;<p><strong>The problem:</strong></p>&#xA;<p><em>Input</em>: An <span class="math-container">$n \times n$</span> matrix of 0's and 1's, and a position <em>pos</em> of this matrix (i.e. a pair of int...
habedi/stack-exchange-dataset
21,515
More than one NFA accepting a given language
<p>While going through certain problems. it seems that more than one NFA is possible for the given language. Is it so? </p>&#xA;&#xA;<p>For example for drawing: NFA ending with 1 where $\Sigma=\{0,1\}$ is</p>&#xA;&#xA;<p><img src="https://i.stack.imgur.com/dUGPO.png" alt="From Wikipedia page on NFA"></p>&#xA;&#xA;<p>an...
automata finite automata
1
More than one NFA accepting a given language -- (automata finite automata) <p>While going through certain problems. it seems that more than one NFA is possible for the given language. Is it so? </p>&#xA;&#xA;<p>For example for drawing: NFA ending with 1 where $\Sigma=\{0,1\}$ is</p>&#xA;&#xA;<p><img src="https://i.stac...
habedi/stack-exchange-dataset
21,518
Creating a Deterministic Push Down Automata
<p>I saw this old post on stack overflow of a PDA that accepts a language where there are exactly twice as many a's as there are b's. The image they used is below and so is the link to the post itself.</p>&#xA;&#xA;<p><a href="https://stackoverflow.com/questions/7018113/what-language-does-this-pushdown-automata-pda-acc...
automata pushdown automata nondeterminism
1
Creating a Deterministic Push Down Automata -- (automata pushdown automata nondeterminism) <p>I saw this old post on stack overflow of a PDA that accepts a language where there are exactly twice as many a's as there are b's. The image they used is below and so is the link to the post itself.</p>&#xA;&#xA;<p><a href="ht...
habedi/stack-exchange-dataset
21,520
Which Type of Grammar is this?
<p>I am learning Compiler Design. Can somebody explain what type of Grammar this is? The answer given is $LL(1)$ but there exists a left recursion in the grammar so it cannot be $LL(1)$. I derived the parse table it had conflicts. Am I doing some thing wrong or is the answer given wrong? </p>&#xA;&#xA;<p>My texbook def...
formal grammars compilers parsing
1
Which Type of Grammar is this? -- (formal grammars compilers parsing) <p>I am learning Compiler Design. Can somebody explain what type of Grammar this is? The answer given is $LL(1)$ but there exists a left recursion in the grammar so it cannot be $LL(1)$. I derived the parse table it had conflicts. Am I doing some thi...
habedi/stack-exchange-dataset
21,525
Showing that the entropy of i.i.d. random variables is the sum of entropies
<p>The shannon entropy of a random variable $Y$ (with possible outcomes $\Sigma=\{\sigma_{1},...,\sigma_{k}\}$) is given by<br>&#xA;$H(Y)=-\sum\limits_{i=1}^{k}P(Y=\sigma_{i})\;\log(P(Y=\sigma_{i}))$. </p>&#xA;&#xA;<p>For a second random variable $X=X_{1}X_{2}...X_{n}$, where all $X_{i}$'s are independent and equally ...
information theory entropy
1
Showing that the entropy of i.i.d. random variables is the sum of entropies -- (information theory entropy) <p>The shannon entropy of a random variable $Y$ (with possible outcomes $\Sigma=\{\sigma_{1},...,\sigma_{k}\}$) is given by<br>&#xA;$H(Y)=-\sum\limits_{i=1}^{k}P(Y=\sigma_{i})\;\log(P(Y=\sigma_{i}))$. </p>&#xA;&...
habedi/stack-exchange-dataset
21,531
Are there regular languages between every two non-regular languages?
<p>I have a question regarding regular languages. Given that $L_1$ and $L_2$ are non-regular languages, can a regular language $L$ exist so it is a subset of $L_2$ and $L_1$ subset of $L$?</p>&#xA;&#xA;<p>To be more specific:</p>&#xA;&#xA;<p>$\qquad L_1 \subset L \subset L_2$</p>&#xA;&#xA;<p>for $L_1, L_2$ non-regular ...
formal languages regular languages
1
Are there regular languages between every two non-regular languages? -- (formal languages regular languages) <p>I have a question regarding regular languages. Given that $L_1$ and $L_2$ are non-regular languages, can a regular language $L$ exist so it is a subset of $L_2$ and $L_1$ subset of $L$?</p>&#xA;&#xA;<p>To be ...
habedi/stack-exchange-dataset
21,537
Is equivalence of CFGs decidable for finite sets of grammars?
<p>Is there a way to show that for all <em>finite</em> sets $S$ of context free grammars, there exists a Turing Machine $M$ such that for all grammars $G_1, G_2 \in S$, we have that $M(G1,G2)$ terminates and answer yes if and only if $L(G_1)=L(G_2)$? Is that even true?</p>&#xA;&#xA;<p>I know that this problem is in gen...
computability undecidability
1
Is equivalence of CFGs decidable for finite sets of grammars? -- (computability undecidability) <p>Is there a way to show that for all <em>finite</em> sets $S$ of context free grammars, there exists a Turing Machine $M$ such that for all grammars $G_1, G_2 \in S$, we have that $M(G1,G2)$ terminates and answer yes if an...
habedi/stack-exchange-dataset
21,539
What Do Logical Operators In a Grammar Mean?
<p>Is there a way to figure out what the following CFG accepts?</p>&#xA;&#xA;<p>$\qquad\begin{align}&#xA; S &amp;\to S \vee T \mid T \\&#xA; T &amp;\to T \wedge F \mid F \\ &#xA; F &amp;\to p \mid\; \thicksim p&#xA;\end{align}$</p>&#xA;&#xA;<p>I'm confused by the boolean algebra symbols. I know the first is S or T, ...
context free formal grammars
1
What Do Logical Operators In a Grammar Mean? -- (context free formal grammars) <p>Is there a way to figure out what the following CFG accepts?</p>&#xA;&#xA;<p>$\qquad\begin{align}&#xA; S &amp;\to S \vee T \mid T \\&#xA; T &amp;\to T \wedge F \mid F \\ &#xA; F &amp;\to p \mid\; \thicksim p&#xA;\end{align}$</p>&#xA;&#...
habedi/stack-exchange-dataset
21,544
Do Kleene star and complement commute?
<p>I am having hard time solving the following problem.</p>&#xA;&#xA;<blockquote>&#xA; <p>Are there any languages for which&#xA; $$&#xA;\overline{L^*} = (\overline{L})^*&#xA;$$</p>&#xA;</blockquote>&#xA;&#xA;<p>Assuming $\emptyset^* = \emptyset$, if I consider $\Sigma = \{a\}$ and L = $\Sigma^*$, I get that $L^* = L$...
formal languages regular languages closure properties
1
Do Kleene star and complement commute? -- (formal languages regular languages closure properties) <p>I am having hard time solving the following problem.</p>&#xA;&#xA;<blockquote>&#xA; <p>Are there any languages for which&#xA; $$&#xA;\overline{L^*} = (\overline{L})^*&#xA;$$</p>&#xA;</blockquote>&#xA;&#xA;<p>Assuming ...
habedi/stack-exchange-dataset
21,552
Appropriate minor to go with CS major
<p>I thought this would be the best place for a question like this. Anyway, I was wondering what minor would go well with a Computer Science degree. I was considering a minor in math but I am not entirely sure if that could help out or not. I am currently a second semester freshman and I suppose that this is the best/l...
education
1
Appropriate minor to go with CS major -- (education) <p>I thought this would be the best place for a question like this. Anyway, I was wondering what minor would go well with a Computer Science degree. I was considering a minor in math but I am not entirely sure if that could help out or not. I am currently a second se...
habedi/stack-exchange-dataset
21,563
VC dimension of complement
<p>Let $C\subseteq 2^X$ be a concept class over $X$ and let $\bar{C}:=\{X\setminus c\mid c\in C\}$ be the complement. Show that $VCdim(C)=VCdim(\bar{C})$.</p>&#xA;&#xA;<p>Proof:</p>&#xA;&#xA;<p>Let $d:=VC_{dim}(C)$, then there exists $S\subseteq X$, $|S|=d$, s.t. $S$ is shattered by $C$.</p>&#xA;&#xA;<p>Let $d':=VC_{di...
machine learning vc dimension
1
VC dimension of complement -- (machine learning vc dimension) <p>Let $C\subseteq 2^X$ be a concept class over $X$ and let $\bar{C}:=\{X\setminus c\mid c\in C\}$ be the complement. Show that $VCdim(C)=VCdim(\bar{C})$.</p>&#xA;&#xA;<p>Proof:</p>&#xA;&#xA;<p>Let $d:=VC_{dim}(C)$, then there exists $S\subseteq X$, $|S|=d$,...
habedi/stack-exchange-dataset
21,564
why is this computational method by Knuth "effective" and "powerful"?
<p>This is a follow-up question regarding Knuth's one formulation of the concept of an algorithm <a href="https://cs.stackexchange.com/questions/1666/please-explain-this-formal-definition-of-computation">here</a>. I am asking it here because I do not have enough reputation to post a comment to that question. To make my...
computation models
1
why is this computational method by Knuth "effective" and "powerful"? -- (computation models) <p>This is a follow-up question regarding Knuth's one formulation of the concept of an algorithm <a href="https://cs.stackexchange.com/questions/1666/please-explain-this-formal-definition-of-computation">here</a>. I am asking ...
habedi/stack-exchange-dataset
21,574
Why can't you write the 2-paths problem as a max-flow problem?
<p>This is a follow-up question to <a href="https://cstheory.stackexchange.com/questions/20989/graph-problems-which-are-np-complete-on-directed-graphs-but-polynomial-on-undire/20991#comment55620_20991">this</a>. Consider the 2-paths problem:</p>&#xA;&#xA;<blockquote>&#xA; <p>Given a directed graph $D=(V,A)$ and pairs ...
complexity theory graphs network flow
1
Why can't you write the 2-paths problem as a max-flow problem? -- (complexity theory graphs network flow) <p>This is a follow-up question to <a href="https://cstheory.stackexchange.com/questions/20989/graph-problems-which-are-np-complete-on-directed-graphs-but-polynomial-on-undire/20991#comment55620_20991">this</a>. Co...
habedi/stack-exchange-dataset
21,575
What is the result of multiplying O(n) and Ω(n)?
<p>If $f(x) = \Omega(n)$ and $g(x)= O(n)$, what would be the order of growth of $f(x) \cdot g(x)$ ?</p>&#xA;&#xA;<p>First I figured it should $\Theta(n)$ , as two extremes would cancel each other and the order of growth will be same as $n$</p>&#xA;&#xA;<p>But, where I came across this question, the answer given was $\...
asymptotics landau notation
1
What is the result of multiplying O(n) and Ω(n)? -- (asymptotics landau notation) <p>If $f(x) = \Omega(n)$ and $g(x)= O(n)$, what would be the order of growth of $f(x) \cdot g(x)$ ?</p>&#xA;&#xA;<p>First I figured it should $\Theta(n)$ , as two extremes would cancel each other and the order of growth will be same as $...
habedi/stack-exchange-dataset
21,580
Find all neighbors at a certain distance, in 3 dimensions
<p>I have two algorithms which I would like to implement:</p>&#xA;&#xA;<p>First, given a (very long) list $\{\mathbf{r}_{i}\}_{i=1}^{n}\subset \mathbb{R}^{3}$, a point $p \in \mathbb{R}^{3}$, and a distance $d&gt;0$, find all $i$ such that $|\mathbf{r}_{i} - \mathbf{p}| &lt; d$.</p>&#xA;&#xA;<p>Currently, I sort the li...
algorithms computational geometry search algorithms
1
Find all neighbors at a certain distance, in 3 dimensions -- (algorithms computational geometry search algorithms) <p>I have two algorithms which I would like to implement:</p>&#xA;&#xA;<p>First, given a (very long) list $\{\mathbf{r}_{i}\}_{i=1}^{n}\subset \mathbb{R}^{3}$, a point $p \in \mathbb{R}^{3}$, and a distanc...
habedi/stack-exchange-dataset
21,583
Total ordering of sets of fixed size
<p>I'm curious if there is a name for this way of ordering finite sets of natural numbers (shown here for the case 3 elements, but can be extended to any number of them):</p>&#xA;&#xA;<pre><code>{0, 1, 2} &lt; {0, 1, 3}&#xA; &lt; {0, 2, 3}&#xA; &lt; {1, 2, 3}&#xA; &lt; {0, 1, 4}&#xA; ...
combinatorics sets order theory
1
Total ordering of sets of fixed size -- (combinatorics sets order theory) <p>I'm curious if there is a name for this way of ordering finite sets of natural numbers (shown here for the case 3 elements, but can be extended to any number of them):</p>&#xA;&#xA;<pre><code>{0, 1, 2} &lt; {0, 1, 3}&#xA; &lt; {0, 2, ...
habedi/stack-exchange-dataset
21,585
Wave propagation in digital image
<p>I believe the following question in summary is: How to approximate Euclidean distance in a digital plane?</p>&#xA;&#xA;<blockquote>&#xA; <p>When a pebble falls on a calm surface of water a circular wave propagates. I want to color the pixels with time to show this effect. So I discretize the time and in each time s...
algorithms computational geometry approximation
1
Wave propagation in digital image -- (algorithms computational geometry approximation) <p>I believe the following question in summary is: How to approximate Euclidean distance in a digital plane?</p>&#xA;&#xA;<blockquote>&#xA; <p>When a pebble falls on a calm surface of water a circular wave propagates. I want to colo...
habedi/stack-exchange-dataset
21,586
Why the given NFA is not possible
<p>I am trying to construct NFA for all languages ending in 00.</p>&#xA;&#xA;<p>I got this </p>&#xA;&#xA;<p><img src="https://i.stack.imgur.com/MKW9H.png" alt="enter image description here"></p>&#xA;&#xA;<p>and this</p>&#xA;&#xA;<p><img src="https://i.stack.imgur.com/gSaQO.png" alt="enter image description here"></p>&#...
automata finite automata
1
Why the given NFA is not possible -- (automata finite automata) <p>I am trying to construct NFA for all languages ending in 00.</p>&#xA;&#xA;<p>I got this </p>&#xA;&#xA;<p><img src="https://i.stack.imgur.com/MKW9H.png" alt="enter image description here"></p>&#xA;&#xA;<p>and this</p>&#xA;&#xA;<p><img src="https://i.stac...
habedi/stack-exchange-dataset
21,593
Induction proof, base case not working but induction step works?
<p>$1+3+5+...+(2n+3)=n^2+4n$</p>&#xA;&#xA;<p>For this series using induction proof. </p>&#xA;&#xA;<p>Base case 1,2,3,.. not working. But induction step works well. </p>&#xA;&#xA;<p>Base case is not given in question.</p>&#xA;
proof techniques induction
1
Induction proof, base case not working but induction step works? -- (proof techniques induction) <p>$1+3+5+...+(2n+3)=n^2+4n$</p>&#xA;&#xA;<p>For this series using induction proof. </p>&#xA;&#xA;<p>Base case 1,2,3,.. not working. But induction step works well. </p>&#xA;&#xA;<p>Base case is not given in question.</p>&#x...
habedi/stack-exchange-dataset
21,613
Why can't we flip the answer of a NDTM efficiently?
<p>I read several times that it is not possible to flip the answer of a NDTM efficiently. However, I don’t understand why. For instance, given a NDTM $M$ that runs in $O(n)$, <a href="http://www.cs.princeton.edu/theory/complexity/diagchap.pdf">this text</a> (section 3.3) states that it is unclear how another NDTM $T$ c...
complexity theory turing machines
1
Why can't we flip the answer of a NDTM efficiently? -- (complexity theory turing machines) <p>I read several times that it is not possible to flip the answer of a NDTM efficiently. However, I don’t understand why. For instance, given a NDTM $M$ that runs in $O(n)$, <a href="http://www.cs.princeton.edu/theory/complexity...
habedi/stack-exchange-dataset
21,620
lexicographic depth-first search complexity class
<p>It seems to me to be incorrect to say that lexicographic DFS is P-complete, since it isn't a decision problem. There is a corresponding decision problem, first DFS ordering, which is known to be P-complete. However, I want to talk about complexity of DFS, not it's decision problem. What complexity class should I say...
complexity theory search algorithms
1
lexicographic depth-first search complexity class -- (complexity theory search algorithms) <p>It seems to me to be incorrect to say that lexicographic DFS is P-complete, since it isn't a decision problem. There is a corresponding decision problem, first DFS ordering, which is known to be P-complete. However, I want to ...
habedi/stack-exchange-dataset
21,625
Why does making a seemingly insignificant edit to an executable's machine code return errors?
<p>First of all, I would like to apologize if this question is in the wrong section. For all I know, it could be placed in Super User, Reverse Engineering, or Stack Overflow.</p>&#xA;&#xA;<p>Now lets get back the experiment I tried:</p>&#xA;&#xA;<p>What I did was took an executable file and changed its file type to a t...
operating systems
1
Why does making a seemingly insignificant edit to an executable's machine code return errors? -- (operating systems) <p>First of all, I would like to apologize if this question is in the wrong section. For all I know, it could be placed in Super User, Reverse Engineering, or Stack Overflow.</p>&#xA;&#xA;<p>Now lets get...
habedi/stack-exchange-dataset