Added reduce functions