Mathematics of D5 Network