added function 'partition', 'repartition' and new resources