add membership related function.