Calculation of the entropy of liquid chlorine and bromine by computer simulation