The Single Linkage algorithm by SIBSON named SLINK gives time complexity of O(n2) and space complexity of O(n).Is there anyone who can explain me that how the distance updation part of SLINK is done after merging 2 clusters .Say suppose , a,b,v,d,e are 5 points .We are creating the Av,Ad array by forming the distance matrix only once .Now after merging say aUb , the algorithm says it finds the nearest neighbour of aUb.But it does not store the distance matrix to reduce space complexity , then how can it determine the nearest neighbour of aUb?