added stacked command, made conversions more precisesly, added inverse to factory