done for sequential implementation