edges: compute depth value
edges: special matrix inversion