tensor replacement (fix indices in powers)