Don't know if you are aware, but since each line in edit distance PD depends only in the previous one, you can keep only the two last lines. This way you can achieve O(n) space complexity, instead of the O(n^2) in the naïve implementation.
Example in Python (assuming cost 2 for replacement, 3 for addition and 5 for deletion):
def levenshtein(s1, s2):
A = [0]*(len(s2)+1)
B = range(len(s2)+1)
for i, c1 in enumerate(s1, 1):
A[0] = i
for j, c2 in enumerate(s2, 1):
if c1 == c2:
A[j] = B[j-1]
else:
A[j] = min(B[j-1]+2, A[j-1]+3, B[j]+5)
A,B = B,A
return B[len(s2)]
print levenshtein('kitten', 'sitting')