Iterative Proportional Fitting Procedure (IPFP)
- IPFP is an algorithm that iteratively scales matrices or tensors to meet prescribed marginal totals while minimizing Kullback–Leibler divergence.
- It employs alternating row and column scaling (or cyclic marginal updates in higher dimensions) to achieve maximum entropy solutions in statistical models.
- IPFP is applied to diverse problems including contingency table fitting, network reconstruction, and optimal transport, with geometric convergence guarantees.
The Iterative Proportional Fitting Procedure (IPFP), also referred to as Sinkhorn's algorithm or matrix scaling, is a foundational routine in statistical inference, numerical optimization, and network theory. IPFP seeks—given a nonnegative tensor or probability measure and a collection of linear marginal constraints—a scaled version that exactly matches the prescribed marginals while remaining as close as possible (in Kullback–Leibler divergence) to the original array or measure. Applications span contingency table fitting, entropy-regularized optimal transport, dynamic network reconstruction, copula modeling, and graphical model adjustment.
1. Mathematical Formulation and Algorithmic Structure
Formally, for a nonnegative matrix and strictly positive target marginals , with , the goal is to find such that
IPFP alternates scaling rows and columns:
- Row-scaling:
- Column-scaling:
These updates are succinctly represented as and (Brossard et al., 2016). The limit, when it exists, is always diagonally equivalent to 0 (the IPF-scaling theorem).
In higher dimensions or for general constraints, the algorithm cycles through marginal operators, scaling to match each prescribed marginal in turn (e.g., demographic table fitting with multidimensional marginals) (Nalmpatian et al., 12 Feb 2025).
2. Statistical and Information-Theoretic Foundations
IPFP can be derived as a sequence of alternating I-projections (KL-projections) onto convex sets corresponding to marginal constraints. For a probability mass function (p.m.f.) 1 and prescribed marginals 2, the limiting solution 3 is the unique minimizer of 4 over the set of p.m.f.s with those marginals ("I-projection") (Kojadinovic et al., 2023). In information-theoretic language, this corresponds to finding the maximum entropy distribution that matches the given marginals (subject to support constraints) (Lebacher et al., 2019).
In exponential family or Poisson/log-linear models, IPFP yields the maximum likelihood estimate (MLE) under margin constraints. For example, in the context of network reconstruction, the biproportional Poisson model's log-likelihood reduces to a convex optimization problem whose MLE is obtained via IPFP (Chang et al., 2024). Similarly, classical IPFP for contingency tables is equivalent to cyclic coordinate descent for the Poisson log-likelihood (She et al., 2016).
IPFP also generalizes naturally to information-projection problems in infinite-dimensional function spaces, where rates of convergence engage the geometry of the constraint subspaces (the Friedrichs angle) (Eckstein et al., 27 Feb 2025).
3. Convergence Theory
The convergence of IPFP is governed by combinatorial and algebraic compatibility conditions:
- Existence and uniqueness: There is a unique fit if and only if the set of matrices with the prescribed marginals and support matching 5 is nonempty. The scaling factors converge geometrically, and the process yields a biproportional form 6 (Brossard et al., 2016).
- Divergence and block structure: If the support incompatibility arises (e.g., zeros in 7 incompatible with margin constraints), the full sequence may not converge, but the even and odd subsequences do, yielding at most two distinct limit points, each corresponding to solutions on block-diagonal submatrices (Aas, 2012). These limit points can be efficiently identified by a block-decomposition algorithm based on generalized Hall's conditions (Aas, 2012).
- Generalization and angles: In the context of information projections onto intersections of general linear constraint sets, the rate of convergence is exponentially fast, governed by the angle between the function spaces defining the constraints. More orthogonal constraint spaces accelerate convergence (Eckstein et al., 27 Feb 2025).
- Stability: Quantitative stability, notably in entropy-regularized optimal transport, shows uniform-in-iteration robustness to marginal perturbations, with Lipschitz continuity in Wasserstein metric (Deligiannidis et al., 2021).
- Curved exponential families: For relational models without an overall effect, classical IPFP fails to guarantee normalization. A generalized IPF based on Bregman projections addresses this, cycling through projections onto constraint hyperplanes, possibly requiring normalization by an adjustment factor (Klimova et al., 2013).
4. Practical Algorithms and Extensions
IPFP admits various extensions and computational enhancements:
- Multidimensional fitting: The classical two-marginal IPFP is readily extended to higher-order tables by cycling through marginal scaling operations (e.g., age, gender, smoker status, region in mortality tables) (Nalmpatian et al., 12 Feb 2025).
- Coordinate descent and MM perspective: Interpreted as coordinate descent in a Poisson log-linear model, IPFP supports block updates, randomization (A-IPS), momentum-based acceleration (Q-IPS), and regularization (ridge, lasso penalties) (She et al., 2016). This view enables the use of modern optimization strategies.
- Structured models: In hierarchical and partition models, including decomposable graphical models and staged trees, IPFP computes the MLE with strong theoretical guarantees; for certain algebraic structures (GRIP), exact MLE recovery is achieved in one cycle (Coons et al., 2022).
- Bayesian networks and probabilistic graphical models: IPFP extends to Bayesian networks via E-IPFP and D-IPFP, cycling over marginal and conditional constraints as well as structural constraints to adjust CPTs minimally in KL divergence (Peng et al., 2012).
- Entropy-regularized optimal transport and Schrödinger bridges: In the continuous setting, IPFP (Sinkhorn) is used to solve regularized transport and Schrödinger bridge problems, with alternating updates via scaling potentials and strict contraction properties in Hilbert’s projective metric (Deligiannidis et al., 2021, Kholkin et al., 2024). The algorithm has been extended to iterative proportional Markovian fitting (IPMF), interleaving classical IPFP and Markovian projections for dynamic problems (Kholkin et al., 2024).
5. Applications Across Domains
Contingency Table and Demographic Fitting
IPFP is standard for contingency table fitting with known marginal totals (survey analysis, census data, population demography). Multiway extensions enable high-resolution synthetic microdata generation (mortality simulation for insurance and public health) (Nalmpatian et al., 12 Feb 2025).
Copula-Based Inference
IPFP realizes the nonparametric 8-projection to Fréchet classes, enabling the decomposition of a discrete bivariate distribution into its margins and an underlying discrete copula. It supports nonparametric and parametric estimation, as well as goodness-of-fit testing, for dependence modeling in discrete settings (Kojadinovic et al., 2023).
Network and Matrix Reconstruction
For network reconstruction problems (e.g., interbank lending, dynamic networks), IPFP underlies maximum entropy and maximum likelihood solutions, accommodating both nodal and dyadic covariates and random effects, and providing explicit intervals via bootstrap (Lebacher et al., 2019, Chang et al., 2024).
Bayesian Networks and Knowledge Integration
E-IPFP and D-IPFP provide efficient mechanisms to update probabilistic graphical models (Bayesian networks) under new constraints, optimizing the Kullback–Leibler divergence from the prior under structure and/or local marginal constraints (Peng et al., 2012).
Information Decomposition and Multimodal Analysis
IPFP enables the decomposition of predictive information into unique, redundant, and synergistic components in representation learning, providing post-hoc quantification of modality contributions in multimodal networks via Partial Information Decomposition (Amit et al., 22 Nov 2025).
6. Limitations, Controversies, and Alternatives
- Support incompatibility and nonuniqueness: For input matrices with incompatible zeros, IPFP may converge slowly or not at all. In these cases, effective algorithms identify the feasible blocks and accelerate convergence (Aas, 2012, Brossard et al., 2016).
- Preservation of association structure: IPFP preserves multiplicative association (odds ratios) from the initial table. For counterfactual analysis (e.g., simulating hypothetical populations with fixed ordinal association), IPFP can impose undesired trends, necessitating alternatives such as the NM-method, which preserves ordinal indicators and yields more substantively plausible counterfactuals (Naszodi, 2023).
- Extensions and computational scaling: Large-scale problems benefit from block updates, randomization, and acceleration strategies, but the order of constraint application can affect convergence (She et al., 2016, Peng et al., 2012). For highly complex Bayesian networks, decomposed updates (D-IPFP) yield vast runtime improvements.
- Curved models and normalization: In curved exponential families lacking an overall effect, standard IPFP fails to maintain probability normalization, requiring generalized IPF with appropriate re-scaling (Klimova et al., 2013).
7. Recent Developments and Ongoing Research
Recent research has sharpened convergence analysis, establishing exponential rates and linking them explicitly to the geometry of constraint subspaces (Eckstein et al., 27 Feb 2025). Novel algorithmic variants, such as Iterative Proportional Markovian Fitting (IPMF), unify Sinkhorn-type marginal matching and Markovian fitting for dynamic and adversarial generative models, with convergence and empirical performance guarantees in high-dimensional domains (Kholkin et al., 2024). Information decomposition frameworks now leverage IPFP for scalable, retrain-free analyses of deep network representations (Amit et al., 22 Nov 2025). The continued interplay between combinatorial structure, information geometry, and algorithmic innovation defines the evolving landscape of IPFP research and its multi-domain methodological reach.