  Modeling the whole cardiac function involves the solution of several complex
multi-physics and multi-scale models that are highly computationally demanding,
which call for simpler yet accurate, high-performance computational tools.
Despite the efforts made by several research groups, no software for
whole-heart fully-coupled cardiac simulations in the scientific community has
reached full maturity yet. In this work we present the first publicly released
package of lifex, a high-performance Finite Element solver for multi-physics
and multi-scale problems developed in the framework of the iHEART project. The
goal of lifex is twofold. On the one side, it aims at making in silico
experiments easily reproducible and accessible to a wide community of users,
including those with a background in medicine or bio-engineering. On the other
hand, as an academic research library lifex can be exploited by scientific
computing experts to explore new mathematical models and numerical methods
within a robust development framework. lifex has been developed with a modular
structure and will be released bundled in different modules. The tool presented
here proposes an innovative generator for myocardial fibers based on
Laplace-Dirichlet Rule-Based Methods, which are the essential building blocks
for modeling the electrophysiological, mechanical and electromechanical cardiac
function, from single-chamber to whole-heart simulations. This report comes
with an extensive technical and mathematical documentation to welcome new users
to the core structure of a prototypical lifex application and to provide them
with a possible approach to include the generated cardiac fibers into more
sophisticated computational pipelines.
