An algorithm is a sequence of well-defined steps that defines an abstract solution to a problem. Use this tag when your issue is related to algorithm design.

learn more… | top users | synonyms (2)

7
votes
0answers
292 views

GLSL-ES Random grainy noise with FP16 limit

I am trying to write a compact and simple noise function with a strictly FP16 limit. This is with what I came out so far, but I think somewhere on the operation the number gets too small for fract or ...
4
votes
0answers
197 views

Floating Point Divider Hardware Implementation Details

I am trying to implement a 32-bit floating point hardware divider in hardware and I am wondering if I can get any suggestions as to some tradeoffs between different algorithms? My floating point unit ...
4
votes
0answers
97 views

Generating suffix tree of string S[2..m] from suffix tree of string S[1..m]

Is there a fast (O(1) time complexity) way of generating a suffix tree of string S[2..m] from suffix tree of string S[1..m]? I am familiar with Ukkonen's, so I know how to make fast suffix tree of ...
4
votes
0answers
413 views

Distributed local clustering coefficient algorithm (MapReduce/Hadoop)

I have implemented MapReduce paradigm based local clustering coefficient algorithm. However I have run into serious troubles for bigger datasets or specific datasets (high average degree of a node). I ...
3
votes
0answers
76 views

Lehmer's extended GCD algorithm implementation

While doing my own BigInteger implementation, I got stuck with the extended GCD algorithm, which is fundamental for finding modular multiplicative inverse. As the well-known Euclidean approach ...
3
votes
0answers
88 views

Karatsuba Multiplication for unequal size, non-power-of-2 operands

What's the most efficient way to implement Karatsuba large number multiplication with input operands of unequal size and whose size is not a power of 2 and perhaps not even an even number? Padding the ...
3
votes
0answers
542 views

bevel or sunken effect algorithm on c#

I am looking for ways to generate the bevel/emboss effect for a set of random closed beizier shapes. I came across the following post which seems to match my requirement. ...
2
votes
0answers
59 views

undecomposability of a non-negative integer matrix

I am looking for an algorithm to test whether a non-negative dxd integer matrix is undecomposable. I call a matrix undecomposable if it can not be written as a product of two non-negative dxd integer ...
2
votes
0answers
56 views

Handle rowspan when tr show/hide

If there is a table with some rowspan in it, I would like to: Whenever a tr is hidden, the table will rearrange itself correctly Whenever a tr is shown again, it will be restored to original state ...
2
votes
0answers
71 views

Fast treewidth algorithms

I would like to compute the treewidth of a graph. There are really good heuristics for other hard graph problems such as graph isomorphism VF2 algorithm steps with example with code available in ...
2
votes
0answers
71 views

Working formation algorithms into football simulation

After a lot of digging i found this question Improving soccer simulation algorithm and converted it over to C#, and have added in extras such as fitness, morale, various statistics for players which ...
2
votes
0answers
46 views

Networkx: Use common function for edge weight calculation

Suppose I have a function euc_2d(graph, n1, n2) that calculates the euclidean distance between two nodes of the same graph. Each nodes has a given pos=(x,y) which is assigned on graph creation. ...
2
votes
0answers
37 views

LSM tree with a row merge function

I'm looking for a Java library or package or just some code that will help me implement a modified LSM tree. Here's the issue: My system needs to write key/value pairs to a table. key0/value0 ...
2
votes
0answers
57 views

Calculating coordinates for directed unweighted graph

I'm looking for a one-pass algorithm (or ideas of how to write it myself) that can calculate the two or three dimensional coordinates for a directed, unweighted graph. The only metadata the vertices ...
2
votes
0answers
120 views

Why does my string permutation algorithm only work with 3 or less letters?

The Code: function recursiveParse(letters, index) { var i, index = index || 0; stringOfLetters = ''; while(index < letters.length) { stringOfLetters += ...

1 2 3 4 5 182
15 30 50 per page