written out chain-making functions