adding matrix transformer