added basic functionality for coding sets