all functions written