fixed typo in cw dec function