Most Popular

1500 questions
14
votes
1 answer

About Codd's reduction algorithm

Codd's Algorithm converts an expression in tuple relational calculus to Relational Algebra. Is there a standard implementation of the algorithm? Is this algorithm used anywhere? (It seems that the industry only needs SQL and variants, I'm not sure…
PKG
  • 1,489
  • 10
  • 15
14
votes
2 answers

If lower bound of a problem is exponential then is it NP?

Assuming that we have a problem $p$ and we showed that the lower bound for solving $p$ is $\mathcal{\Omega}(2^n)$. can lower bound $\mathcal{\Omega}(2^n)$ implies the problem in $NP$?
kelalaka
  • 1,171
  • 1
  • 10
  • 19
14
votes
6 answers

Lambda Calculus Generator

I don't know where else to ask this question, I hope this is a good place. I'm just curious to know if its possible to make a lambda calculus generator; essentially, a loop that will, given infinite time, produce every possible lambda calculus…
MetaStack
  • 337
  • 2
  • 12
14
votes
1 answer

Incremental strongly connected components

For a changing directed graph, I would like to maintain information about strongly connected components. The graph operations are incremental: only vertex addition and edge addition. What data structures achieve the best known amortized complexity…
kne
  • 2,358
  • 9
  • 17
14
votes
1 answer

Interesting problem on sorting

Given a tube with numbered balls (random). The tube has holes to remove a ball. Consider the following steps for one operation: You can pick one or more balls from the holes and remember the order in which you picked the balls. You need to tilt the…
rakesh
  • 141
  • 2
14
votes
2 answers

Will this program terminate for every Integer?

In a Part Test for GATE Preparation there was a question : f(n): if n is even: f(n) = n/2 else f(n) = f(f(n-1)) I answered "It will terminate for all integers", because even for some negative integers, it will terminate as Stack Overflow…
Prakhar Londhe
  • 251
  • 2
  • 7
14
votes
5 answers

How to prove the existence of a number which cannot be written by any algorithm?

I have the problem: Show that there exists a real number for which no program exists that runs infinitely long and writes that number's decimal digits. I suppose it can be solved by reducing it to the Halting problem, but I have no idea how to…
fresheed
  • 143
  • 1
  • 6
14
votes
1 answer

What kind of math problems can be solved by automated theorem provers?

Can I prove following statements with using available automated theorem provers? $(a+b)^2=a^2+b^2+2ab$. If $ 11 \mid 2a-3b$, then $ 11 \mid 7a-5b $. If $ ax^2+bx+c=0$, then $x=\frac{-b\pm\sqrt{b^2-4ac} }{2a}$. If $a$ is even then $4a$ is…
Math-fort
  • 173
  • 6
14
votes
2 answers

Is there a concept for an algorithm computing a function by first finding another algorithm?

If I understand it correctly, an algorithm that computes the value of a real function $f$ has computational complexity $O(g(n))$ if the following holds: When we compute $f$ to precision $\delta$ requires on the order of $g(n)$ steps. However, what…
user56834
  • 4,244
  • 5
  • 21
  • 35
14
votes
2 answers

Solving functional equations for unknown functions in lambda calculus

Are there any techniques for solving functional equations for unknown functions in lambda calculus? Suppose I have the identity function defined extensionally as such: $I x = x$ (that is, by writing down an equation for the expected behaviour of…
BarbaraKwarc
  • 261
  • 1
  • 6
14
votes
2 answers

Do system calls always means a context switch?

When a system call takes place some kernel code must be executed. If some kernel code is being executed it means it can alter register values. So before this code gets executed the old process state must be saved. This is called context switch. Now…
Kishan Kumar
  • 717
  • 1
  • 8
  • 24
14
votes
1 answer

Monadic Second Order Logic for Dummies

I am programmer with a grip on automata, but not on logic. I read in papers that the two are very tightly related. Deterministic Finite Automata (DFA), Tree Automata and Visibly Pushdown Automata are all related to Monadic Second Order Logic…
14
votes
4 answers

Are there any algorithms or data structures that need to find the median value of a set?

I have been reading this book for my class, Randomized Algorithms. In this particular book, there is a whole section dedicated to finding the median of an array using random selection, that leads to a more efficient algorithm. Now, I wanted to know…
SDG
  • 403
  • 1
  • 5
  • 13
14
votes
1 answer

How is PowerPoint Turing complete?

From my understanding, Turing complete means that the program or machine can complete any computation that a Turing machine can complete, which to me means any computation. So how can something like HTML or PowerPoint be Turing complete?
a13a22
  • 243
  • 1
  • 2
  • 5
14
votes
2 answers

Proving a binary tree has at most $\lceil n/2 \rceil$ leaves

I'm trying to prove that a binary tree with $n$ nodes has at most $\left\lceil \frac{n}{2} \right\rceil$ leaves. How would I go about doing this with induction? For people who were following in the original question about heaps, it has been moved…