jaxvacua.flux_utils#

Stateless flux-vector and solution-classification helpers.

Purpose#

Provide small, reusable helpers for converting flux representations, normalising candidate solutions and applying post-processing checks outside the main FluxEFT and FluxVacuaFinder classes.

Main public API#

  • PFV conversions: flux_to_pfv, pfv_to_flux and pfv_to_moduli.

  • Solution identity and classification: dedup_key, classify_solution and is_physical.

  • Fundamental-domain mapping: map_to_fd and class methods that delegate to this module.

Design notes#

Functions are written to be attached to or called from EFT/search objects and therefore take self as their first argument. Keeping this code stateless reduces coupling between solver workflows and post-hoc analysis.

Role in solver workflows#

This module collects stateless helpers used by flux EFTs and vacuum finders. The functions convert between integral flux vectors and PFV variables, derive PFV-level moduli, and post-process candidate solutions after a numerical search.

PFV and flux conversion workflow#

flux_to_pfv extracts the PFV variables from a full flux vector, pfv_to_flux reconstructs compatible flux data, and pfv_to_moduli computes the associated moduli at PFV level. These helpers are useful when a search alternates between a full flux description and the reduced PFV description used by specialised conifold or ISD-inspired pipelines.

Solution post-processing#

dedup_key builds stable keys for identifying repeated candidates, classify_solution labels the outcome of a solver run, is_physical applies the physicality checks used by the finder, and map_to_fd maps solutions to a chosen fundamental domain before comparison or storage.

PFV algebra#

flux_to_pfv(self, flux)

Returns M- and K-vector specifying PFV from full flux vector.

pfv_to_flux(self, M, K)

Returns full flux vector from M- and K-vector specifying PFV.

pfv_to_moduli(self, M, K, tau)

Returns values of the complex structure moduli at the level of the PFV.

Solution processing#

dedup_key(moduli, tau, fluxes[, n_digits])

Build a hashable dedup key from a single (moduli, tau, fluxes) triple.

classify_solution(model, x, flux[, noscale, ...])

Classify a converged critical-point candidate (x, flux).

is_physical(model, sampler, x[, moduli_max, ...])

Decide whether the converged candidate point x lies in the physical region of moduli space.

map_to_fd(model, moduli, tau, fluxes[, enabled])

Optionally map (moduli, tau, fluxes) to the \(\text{SL}(2,\mathbb{Z}) \times\) monodromy fundamental domain via FluxEFT.map_to_fd(), handling the numpy/JAX boundary so call sites in eager Python loops stay clean.