rearrange the order of variables, prelimenary rational type support