Added attribution to the paper this algorithm is from
Added initial draft of c code