Papers
Topics
Authors
Recent
Search
2000 character limit reached

SWIM: Stochastic Warm Inflation Module to generate and analyse Warm Inflationary power spectrum

Published 27 Apr 2026 in astro-ph.CO, gr-qc, hep-ph, and hep-th | (2604.24654v2)

Abstract: Numerical analysis to determine the form of the scalar power spectrum in Warm Inflationary paradigm is inevitable. One further needs numerical techniques to analyse any Warm Inflation model with the current observational data through the MCMC codes that are available publicly, like COSMOMC or Cobaya. We present SWIM (Stochastic Warm Inflation Module) written in C++ and Python, that not only helps generate the Warm Inflationary scalar power spectrum, either semi-analytically or fully numerically, but also is integrated with Cobaya enabling the user to constrain the model parameters with current CMB data and thus to put any Warm Inflation model to test. SWIM numerically solves the standard stochastic perturbation equations of Warm Inflation without any approximations, uses machine learning techniques to speed up the MCMC analysis while analysing the fully numerical power spectrum that significantly reduces the computational cost, and is able to accommodate any Warm Inflation model with any form of inflationary potential and dissipative coefficient for numerical analysis. We show that SWIM, in most of the cases, outperforms other numerical codes on Warm Inflation that are designed to yield only the semi-analytical power spectrum as far as the runtimes are concerned. We further point out that there can be situations where the semi-analytical way of determining the scalar power spectrum in Warm Inflation can fall short, and one needs the full numerical power spectrum for parameter estimation given the observational data. In such cases, SWIM is the only code available so far that is designed to perform the task. Hence, SWIM offers a complete numerical platform for thorough analysis of Warm Inflation models against the current cosmological data. SWIM has been made publicly available at https://github.com/umg-kmr/SWIM.

Authors (2)

Summary

  • The paper introduces SWIM, a tool that accurately models warm inflation by solving stochastic evolution equations and computing the parameter-dependent G(Q) correction factor.
  • It employs both semi-analytical and full-numerical modules, enhanced with ML emulation to efficiently integrate with Bayesian parameter inference frameworks.
  • Validation against existing tools demonstrates SWIM’s robustness across different dissipative regimes, providing improved precision for cosmological data analysis.

SWIM: A Comprehensive Tool for Modeling and Analysis of Warm Inflationary Power Spectra

Overview of Warm Inflation and Motivations for Numerical Approaches

Warm Inflation (WI) represents a generically viable alternative to Cold Inflation (CI), characterized by the continuous dissipation of inflaton energy to a coexisting radiation bath. The dissipative dynamics introduce additional friction, facilitating slow-roll evolution even with steep potentials, and eliminating the need for a separate reheating phase. WI is compatible with a variety of scalar potentials—including those unsuitable for CI due to excessive tensor production or swampland conjecture constraints—and naturally yields sub-Planckian field excursions preferred by current cosmological data.

The core challenge addressed by SWIM is the inherent complexity of WI: coupled evolution of inflaton and radiation bath, temperature-dependent dissipative coefficients, and stochastic perturbations arising from thermal and quantum fluctuations. Accurate determination of the scalar power spectrum is impractical analytically except via restrictive approximations. Nearly all physically compelling WI models necessitate numerical techniques for their background and perturbative analyses, especially when integrating with MCMC frameworks for parameter estimation.

Structure and Capabilities of the SWIM Software Suite

SWIM is implemented in C++ and Python, structured into three main submodules:

  1. G(Q)G(Q) Submodule: Numerically computes the G(Q)G(Q) correcting factor, quantifying deviations of the true stochastic power spectrum from the semi-analytical approximation. Capable of analyzing arbitrary WI models with customizable inflaton potentials and dissipative coefficients.
  2. Semi-Analytical Power Spectrum Submodule: Utilizes numerically obtained G(Q)G(Q) to construct the semi-analytical power spectrum, integrated with Cobaya for full Bayesian parameter inference using contemporary CMB datasets.
  3. Numerical Power Spectrum Submodule: Directly solves the full stochastic perturbation equations and outputs the raw numerical power spectrum, essential when G(Q)G(Q) exhibits strong dependence on background parameters. This submodule leverages Random Forest regression (RFR) for emulation, reducing computational burden during MCMC analysis. Figure 1

    Figure 1: Illustration of the submodules of SWIM and their workflow.

SWIM distinguishes itself from existing tools (WarmSPy, WI2easy) by its generality, direct integration with Bayesian inference frameworks, and capacity to output fully numerical spectra when semi-analytical approaches break down.

Theoretical Foundations and Implementation Details

SWIM evolves the coupled dynamical equations for the inflaton and radiation bath in e-foldings, allowing for arbitrary functional forms of the potential V(ϕ)V(\phi) and dissipative coefficient Υ(ϕ,T)\Upsilon(\phi, T). The module accommodates thermal noise and quantum fluctuations in the perturbative sector, supporting both correlated and uncorrelated stochastic terms (the former being physically preferred due to energy-momentum conservation).

Perturbatively, SWIM employs the Newtonian gauge for metric fluctuations and solves the stochastic evolution equations for δϕ\delta\phi, δρR\delta\rho_R, ΨR\Psi_R, and α\alpha. Ensemble averaging over numerous realizations yields the numerical curvature power spectrum G(Q)G(Q)0, which can be mapped to the observable primordial power spectrum.

A correction factor G(Q)G(Q)1 is computed as the ratio of numerical to analytical spectra, facilitating the semi-analytical approach:

G(Q)G(Q)2

SWIM is explicitly designed to support arbitrary potentials, general dissipation forms, inclusion/exclusion of thermalization effects, and optional radiation noise terms. Figure 2

Figure 2: Workflow of the G(Q)G(Q)3 submodule, showing user input, internal computations, and output generation.

Numerical Performance, Validation, and Comparison With Existing Codes

SWIM is benchmarked against WI2easy extensively, demonstrating equivalent accuracy for G(Q)G(Q)4 across wide parameter ranges (G(Q)G(Q)5), and verified to match outputs in both weak and strong dissipative regimes. Notably, SWIM and WI2easy diverge mildly in the moderate dissipative regime (G(Q)G(Q)6) when correlated noise is correctly implemented—a physical effect absent in WI2easy’s structure.

SWIM exhibits comparable or superior runtimes relative to WI2easy, despite the added computational overhead of stochastic ensemble averaging. The framework’s robustness is further illustrated by the accurate reproduction of G(Q)G(Q)7 for models with non-trivial dissipative coefficients (e.g., the EFT scenario in [Bastero-Gil:2019gao]), and its ability to handle thermalization effects self-consistently. Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3

Figure 3: Comparison of SWIM and WI2easy outputs for G(Q)G(Q)8 across representative WI models without inflaton thermalization.

Figure 4

Figure 4

Figure 4

Figure 4: Comparison of SWIM and WI2easy G(Q)G(Q)9 outputs for select scenarios with inflaton thermalization and Bose-Einstein distribution.

SWIM’s advantage over WarmSPy is pronounced due to WarmSPy’s restriction to fixed potential forms and constant G(Q)G(Q)0. SWIM’s flexibility permits arbitrary model exploration, and it is the only package capable of directly interfacing with MCMC codes for parameter estimation.

Critical Analysis of Semi-Analytical Methodology and SWIM’s Full-Numerical Approach

A crucial insight provided by SWIM is the discovery that G(Q)G(Q)1 can, in certain particle physics constructions of WI, exhibit substantial dependence on parameters beyond G(Q)G(Q)2—e.g., G(Q)G(Q)3, G(Q)G(Q)4, and other microphysical quantities. Standard semi-analytical pipelines, which fix G(Q)G(Q)5 for one parameter set and reuse it, fail to capture this induced bias, resulting in systematically inaccurate inference. Figure 5

Figure 5

Figure 5: Demonstrates the dependence of G(Q)G(Q)6 on the normalization G(Q)G(Q)7 and relativistic degrees of freedom G(Q)G(Q)8 for a representative WI EFT model.

SWIM circumvents these limitations via its numerical spectrum module: solving the stochastic system for each point in parameter space, and directly integrating the output with likelihood evaluation. To render this computationally tractable, SWIM incorporates ML emulation strategies—most notably RFR—to dynamically decide, during MCMC sampling, when to trust fast surrogate predictions and when to invoke the full solver. Reliability is internally assessed based on variance across the ensemble of trees, ensuring accuracy is not sacrificed.

The emulator is trained during MCMC exploration, mapping background parameters to fitted power spectrum parameters G(Q)G(Q)9. This approach is robust, model-independent, and avoids learning stochastic noise artifacts. Additional uncertainty introduced by solver stochasticity is empirically estimated and incorporated into the likelihood function. Figure 6

Figure 6: Workflow of the numerical power spectrum submodule, including ML emulation and parameter inference.

Figure 7

Figure 7: Posterior distributions for the EFT WI model using both the full numerical solver and the random forest emulator, confirming congruent results.

Practical and Theoretical Implications, Future Directions

SWIM constitutes a comprehensive numerical platform for modeling, simulation, and statistical analysis of WI models, inclusive of all current theoretical advancements. Practically, SWIM enables rigorous evaluation of WI model viability against cosmological datasets, accommodating arbitrary microphysical properties and dissipation scenarios. Theoretically, its demonstration of parameter-dependent G(Q)G(Q)0 provides impetus for reassessment of semi-analytical pipelines and calls for full-numerical approaches, especially for UV-complete models and those motivated by string theory.

The integration of ML emulation into stochastic solver pipelines sets a precedent for computational cosmology, balancing accuracy and scalability. Future extensions may incorporate additional inflationary scenarios, support for tensor spectra, and further optimization of surrogate modeling strategies.

Conclusion

SWIM offers a complete numerical framework for the modeling and analysis of Warm Inflationary power spectra, addressing the need for accurate, flexible, and computationally efficient tools in the study and parameter inference for WI models. The package’s ability to handle arbitrary potentials, dissipative coefficients, and parameter-dependent corrections, coupled with robust performance, enables rigorous theoretical and observational scrutiny of Warm Inflation scenarios. SWIM is uniquely positioned to be the standard for future WI research requiring numerical precision and integration with cosmological data analysis.

Paper to Video (Beta)

No one has generated a video about this paper yet.

Whiteboard

No one has generated a whiteboard explanation for this paper yet.

Open Problems

We haven't generated a list of open problems mentioned in this paper yet.

Collections

Sign up for free to add this paper to one or more collections.