a bunch of useful functions in CCMap