Problem Detail: I have an Euclidean graph: each vertex is a point on the 2D plane, so the weight of each edge is the Euclidean distance between the vertices. I am randomly creating a path thru all the vertices and I Read More …
Category: Uncategorized
Why is Iterative-deepening A* optimal, even without monotonicity?
Problem Detail: Why is it that Iterative-deepening A* is optimal, even without monotonicity? How can I be sure that the first goal reached is the optimal one? Asked By : Lieven Cardoen Answered By : Carlos Linares López In a nutshell: IDA* traverses Read More …
How to generate a pushdown automata for accepting a language?
Problem Detail: I have an exercise in my book to come up with a pushdown automaton accepting a language. The exercise is to come up with a state diagram for the PDA accepting the language of all odd-length strings over ${a, Read More …
Show $x^y$ is a primitive recursive function
Problem Detail: As this thread title gives away I need to prove $x^y$ to be a primitive recursive function. So mathematically speaking, I think the following are the recursion equations, well aware that I am assigning to $0^0$ the value $1$, Read More …
Designing a PDA w/o $epsilon$-moves and $leq 2$ states to accept an $epsilon$-free CFL by final state
Problem Detail: I understand that any CFL can be accepted by a PDA by final state or empty store but I have been rather stumped by this question. The question states that the PDA has at most 2 states. Clearly 1 Read More …
Retrieving data from hash table ordered by insertion time
Problem Detail: By default, a hash table is unordered. I have a simple question on the retrieval of elements in a hash table Can we retrieve elements from a hash table in the same order as they are put inside? Asked Read More …
Is it intuitive to see that finding a Hamiltonian path is not in P while finding Euler path is?
Problem Detail: I am not sure I see it. From what I understand, edges and vertices are complements for each other and it is quite surprising that this difference exists. Is there a good / quick / easy way to see Read More …
Infinite alphabet Turing Machine
Problem Detail: Is a Turing Machine that is allowed to read and write symbols from an infinite alphabet more powerful than a regular TM (that is the only difference, the machine still has a finite number of states)? Intuition tells me Read More …
Heuristic for sokoban puzzle problem
Problem Detail: I am trying to write IDA* for Sokoban puzzle problem (http://en.wikipedia.org/wiki/Sokoban) but It seems that my heuristic is not so good for making the algorithm fast. My heuristic is to consider $h(s)$ as minimum distance between the Player and Read More …
Knapsack problem, partition problem, or in general dynamic algorithm with negative numbers allowed
Problem Detail: How to think about dynamic algorithms which allows negative integers in input (where it’s problematic, because obviously it’s not always the case)? Examples: Partition Problem with negative numbers in set allowed Knapsack problem with negative weights are allowed Is Read More …