Multidimensional Iterative Proportional Fitting