Problem Detail: Christofides’ 1.5-approximation considers complete graphs as inputs, and as I understand this is essential. If the input graph is not complete, how can I add new edges with suitable weights such that the resulting complete graph still satisfies the Read More …
Blog
[Solved]: Create a random graph based on the Degree Distribution and Clustering Coefficient Distribution
Problem Detail: I am currently working with a very large Social Network and I want to recreate this graph with a smaller dimension, using the original Degree Distribution and Clustering Coefficient Distribution. The degree distribution is the relative frequency of vertexes Read More …
[Solved]: Is an inverse homomorphism always a homomorphism?
Problem Detail: Given a homomorphism $h: Sigma rightarrow Delta^*$ such that e.g. $forall a in Sigma: h(a) = delta$, where $delta in Delta$ (i.e. all symbols from the alphabet $Sigma$ have the same image $delta$), is the inverse homomorphism $h^{-1}$ a Read More …
[Solved]: What is a good algorithm for generating random DFAs?
Problem Detail: I am generating random DFAs to test a DFA reduction algorithm on them. The algorithm that I’m using right now is as follows: for each state $q$, for each symbol in the alphabet $c$, add $delta (q, c)$ to Read More …
[Solved]: What is “polynomial delay?”
Problem Detail: I am reading a paper and it uses the expression “polynomial delay” which I don’t understand. It is used in conjonction with the big O notation, which I’m familiar with. Here is a example sentence showing how it is Read More …
[Solved]: Show that if d(n) is O( f (n)) and e(n) is O(g(n)), then d(n)−e(n) is not necessarily O( f (n)−g(n))
Problem Detail: I have this question as an assignment in my Java Algorithms class, and i’m aware that d(n)+e(n) is the same as O(f(n)+g(n)). I dont know why the same doesnt apply to subtracting. Can someone help me? I’m lost.. Asked Read More …
[Solved]: How to convert PDA to CFG
Problem Detail: I learned how to convert context-free grammar to pushdown automata but how can I do the opposite? to convert PDA to CFG? For example: to write CFG for the automata My attempt: $S=A_{03}$ because $q_{color{blue}0}$ is the initial state Read More …
[Solved]: Efficient algorithm for finding weakly connected components
Problem Detail: We recently studied Tarjan’s algorithm at school, which finds all strongly connected components of a given graph. I was curious however how one would find all weakly connected components (I had to search a bit to actually find the Read More …
[Solved]: Subset sum algorithm in O(n³ log n)?
Problem Detail: I think that I have found an algorithm which resolve exactly the subset sum problem in $O(N^3)$ in the worst case, only for positive numbers. After my research, I’m lost between all the algorithms for this problem. $O(2^N*N)$ for Read More …
[Solved]: How are lamport clocks implemented in real world distributed systems?
Problem Detail: Can anyone explain, how lamport clocks implementations are used in modern distributed systems? Can you name an open source package which implements this algorithm? Asked By : Nitish Upreti Answered By : Grisha Weintraub Amazon’s Dynamo [1] is a distributed storage Read More …