MFMassimiliano Fasi

Massimiliano Fasi

*This is an algorithmically generated author record based on publicly available information.

Current Organizations / Institutes

The organizations/institutes from the scholar's latest article

Previous Organizations / Institutes

The organizations / institutes from the scholar's other articles in the past ten years


Massimiliano Fasi has a total of 41 co-authors. Here are the top co-authors by number of shared publications:


Latest Publications

  • Analysis of Floating-Point Matrix Multiplication Computed via Integer Arithmetic

    by Ahmad Abdelfattah, Jack Dongarra, Massimiliano Fasi, Mantas Mikaitis, Françoise Tisseur

    Ootomo, Ozaki, and Yokota [ Int. J. High Perform. Comput. Appl., 38 (2024), pp. 297–313] have proposed a strategy to recast a floating-point matrix multiplication in terms of integer matrix products. The factors [Formula: see text] and [Formula: see text] are split into integer slices, the product of these slices is computed exactly, and [Formula: see text] is approximated by accumulating these integer products in floating-point arithmetic. This technique is particularly well suited to mixed-precision matrix multiply–accumulate units with integer support, such as the NVIDIA tensor cores or the AMD matrix cores. The number of slices allows for performance-accuracy tradeoffs: more slices yield better accuracy but require more multiplications, which in turn reduce performance. We propose an inexpensive way to estimate the minimum number of multiplications needed to achieve a prescribed level of accuracy. Our error analysis shows that the algorithm may become inaccurate (or inefficient) if rows of [Formula: see text] or columns of [Formula: see text] are badly scaled. We perform a range of numerical experiments, both in simulation and on the latest NVIDIA GPUs, that confirm the analysis and illustrate strengths and weaknesses of the algorithm. Reproducibility of computational results. This paper has been awarded the “SIAM Reproducibility Badge: Code and data available” as a recognition that the authors have followed reproducibility principles valued by SISC and the scientific computing community. Code and data that allow readers to reproduce the results in this paper are available at https://github.com/north-numerical-computing/integer-matrix-multiply-experiments and in the supplementary materials ( integer-matrix-multiply-experiments-main.zip [97.8KB]). [Formula: see text]

  • Open Access

    Sharper Bounds on the Required Fixed-Point Precision for Emulating Floating-Point Matrix Multiplication

    by Massimiliano Fasi, Theo Mary, Mantas Mikaitis

    Precision emulation algorithms, such as the Ozaki schemes, can leverage low-precision matrix multiply–accumulate to approximate the product \(AB\) , where \(A\) and \(B\) are high-precision floating-point matrices, via fixed-point arithmetic. A key difficulty of these approaches is that achieving a target floating-point precision \(p\) requires a fixed-point bit width \(w=p+\star\) , where the required number of extra bits \(\star\) depends strongly on the matrix coefficients. The exponent span capacity (ESC), recently introduced in the literature, is an upper bound \(\overline{e}\geq\star\) . For square matrices of order \(n\) , the ESC can be estimated with \(O(n^{2}k)\) operations, where the parameter \(k\) can be increased to improve the sharpness of \(\overline{e}\) . We show that this bound can be very pessimistic, and that for the estimator to be useful, \(k\) must scale with \(n\) , effectively incurring an \(O(n^{3})\) overhead. Building on a rigorous error analysis, we then derive a new formula for \(\star\) , which corroborates the previously proposed formula up to a few bits. We propose an alternative, sharper bound, which can be computed with \(O(n^{2}k)\) operations, where \(k\) becomes independent of \(n\) . Our numerical experiments demonstrate that the current approach can substantially overestimate \(\star\) in many cases, whilst our new approach is almost perfectly sharp even for moderate values of \(k\) . We present strategies for handling matrices with zero coefficients and give a refined formulation for \(\star\) , in which different fixed-point bit widths are used for \(A\) and \(B\) . Overall, this work provides rigorous theoretical accuracy guarantees for fixed-point emulation and a practical algorithm to inexpensively yet sharply determine the required fixed-point bit width.

  • Open Access

    Exact quantum dynamics of Fermi–Hubbard systems using the Gaussian phase-space representation with diffusion gauges

    by François Rousse, Massimiliano Fasi, Andrii Dmytryshyn, Mårten Gulliksson, Joel F. Corney, Magnus Ögren


  • Probabilistic Error Analysis of Limited-Precision Stochastic Rounding

    by El-Mehdi El Arar, Massimiliano Fasi, Silviu-Ioan Filip, Mantas Mikaitis

    Classical probabilistic rounding error analysis is particularly well suited to stochastic rounding (SR), and it yields strong results when dealing with floating-point algorithms that rely heavily on summation. For many numerical linear algebra algorithms, one can prove probabilistic error bounds that grow as [Formula: see text], where [Formula: see text] is the problem size and [Formula: see text] is the unit roundoff. These probabilistic bounds are asymptotically tighter than the worst-case ones, which grow as [Formula: see text]. For certain classes of algorithms, SR has been shown to be unbiased. However, all these results were derived under the assumption that SR is implemented exactly, which typically requires too many random bits to be suitable for practical implementations. We investigate the effect of the number of random bits on the probabilistic rounding error analysis of SR. To this end, we introduce a new rounding mode, limited-precision SR. By taking into account the number [Formula: see text] of random bits used, this new rounding mode matches hardware implementations accurately, unlike the ideal SR operator generally used in the literature. We show that this new rounding mode is biased and that the bias is a function of [Formula: see text]. As [Formula: see text] approaches infinity, however, the bias disappears, and limited-precision SR converges to the ideal, unbiased SR operator. We develop a novel model for probabilistic error analysis of algorithms employing SR. Several numerical examples corroborate our theoretical findings. Reproducibility of computational results. This paper has been awarded the “SIAM Reproducibility Badge: Code and data available” as a recognition that the authors have followed reproducibility principles valued by SISC and the scientific computing community. Code and data that allow readers to reproduce the results in this paper are available at https://github.com/mptorch/mptorch and in the supplementary materials ( mptorch-main.zip [69.0KB]). [Formula: see text]


  • Open Access

    Simulations of quantum dynamics with fermionic phase-space representations using numerical matrix factorizations as stochastic gauges

    by François Rousse, Massimiliano Fasi, Andrii Dmytryshyn, Mårten Gulliksson, Magnus Ögren

    The Gaussian phase-space representation can be used to implement quantum dynamics for fermionic particles numerically. To improve numerical results, we explore the use of dynamical diffusion gauges in such implementations. This is achieved by benchmarking quantum dynamics of few-body systems against independent exact solutions. A diffusion gauge is implemented here as a so-called noise-matrix, which satisfies a matrix equation defined by the corresponding Fokker–Planck equation of the phase-space representation. For the physical systems with fermionic particles considered here, the numerical evaluation of the new diffusion gauges allows us to double the practical simulation time, compared with hitherto known analytic noise-matrices. This development may have far reaching consequences for future quantum dynamical simulations of many-body systems.


  • Open Access

    CPFloat: A C Library for Simulating Low-precision Arithmetic

    by Massimiliano Fasi, Mantas Mikaitis

    One can simulate low-precision floating-point arithmetic via software by executing each arithmetic operation in hardware and then rounding the result to the desired number of significant bits. For IEEE-compliant formats, rounding requires only standard mathematical library functions, but handling subnormals, underflow, and overflow demands special attention, and numerical errors can cause mathematically correct formulae to behave incorrectly in finite arithmetic. Moreover, the ensuing implementations are not necessarily efficient, as the library functions these techniques build upon are typically designed to handle a broad range of cases and may not be optimized for the specific needs of rounding algorithms. CPFloat is a C library for simulating low-precision arithmetics. It offers efficient routines for rounding, performing mathematical computations, and querying properties of the simulated low-precision format. The software exploits the bit-level floating-point representation of the format in which the numbers are stored and replaces costly library calls with low-level bit manipulations and integer arithmetic. In numerical experiments, the new techniques bring a considerable speedup (typically one order of magnitude or more) over existing alternatives in C, C++, and MATLAB. To our knowledge, CPFloat is currently the most efficient and complete library for experimenting with custom low-precision floating-point arithmetic.


  • Matrix Multiplication in Multiword Arithmetic: Error Analysis and Application to GPU Tensor Cores

    by Massimiliano Fasi, Nicholas J. Higham, Florent Lopez, Theo Mary, Mantas Mikaitis

    In multiword arithmetic, a matrix is represented as the unevaluated sum of two or more lower precision matrices, and a matrix product is formed by multiplying the constituents in low prec...


  • Computing the Square Root of a Low-Rank Perturbation of the Scaled Identity Matrix

    by Massimiliano Fasi, Nicholas J. Higham, Xiaobo Liu

    We consider the problem of computing the square root of a perturbation of the scaled identity matrix, [Formula: see text], where [Formula: see text] and [Formula: see text] are [Formula: see text] matrices with [Formula: see text]. This problem arises in various applications, including computer vision and optimization methods for machine learning. We derive a new formula for the [Formula: see text]th root of [Formula: see text] that involves a weighted sum of powers of the [Formula: see text]th root of the [Formula: see text] matrix [Formula: see text]. This formula is particularly attractive for the square root, since the sum has just one term when [Formula: see text]. We also derive a new class of Newton iterations for computing the square root that exploit the low-rank structure. We test these new methods on random matrices and on positive definite matrices arising in applications. Numerical experiments show that the new approaches can yield a much smaller residual than existing alternatives and can be significantly faster when the perturbation [Formula: see text] has low rank.


  • Open Access

    Computational Graphs for Matrix Functions

    by Elias Jarlebring, Massimiliano Fasi, Emil Ringh

    Many numerical methods for evaluating matrix functions can be naturally viewed as computational graphs. Rephrasing these methods as directed acyclic graphs (DAGs) is a particularly effective approach to study existing techniques, improve them, and eventually derive new ones. The accuracy of these matrix techniques can be characterized by the accuracy of their scalar counterparts, thus designing algorithms for matrix functions can be regarded as a scalar-valued optimization problem. The derivatives needed during the optimization can be calculated automatically by exploiting the structure of the DAG in a fashion analogous to backpropagation. This article describes GraphMatFun.jl , a Julia package that offers the means to generate and manipulate computational graphs, optimize their coefficients, and generate Julia, MATLAB, and C code to evaluate them efficiently at a matrix argument. The software also provides tools to estimate the accuracy of a graph-based algorithm and thus obtain numerically reliable methods. For the exponential, for example, using a particular form (degree-optimal) of polynomials produces implementations that in many cases are cheaper, in terms of computational cost, than the Padé-based techniques typically used in mathematical software. The optimized graphs and the corresponding generated code are available online.