fix bugs with rank exp in generic exp