implemented usage of transformation rules
fixed bug if bits smaller then 1 byte