add complement encoder/decoder