lsolve(1)
β¨ lsolve β NAME β¨
okay so bestie, meet lsolve: a linear solver for sparse matrices. that's it, that's the whole job. she solves. she slays. π
π¦ SYNOPSIS π¦
lsolve matrix_filename rhs_setting solution_filename rhistory_filename [options]
like. four positional args and then whatever options you're feeling. no biggie. π«Ά
πΈ DESCRIPTION πΈ
so here's the tea. this program inputs the data of the coefficient matrix from matrix_filename and then solves the linear equation
A*x = b
using the solver that you picked in the options. then it writes the solution out to solution_filename in the extended Matrix Market format</> and drops the residual history into rhistory_filename in the PLAIN format</> (peep the Appendix of the Lis User Guide for that one, iykyk). and for matrix_filename, both the extended Matrix Market format and the Harwell-Boeing format are supported. versatile queen. π
one of these values can be specified by rhs_setting:
0β use the right hand side vectorbincluded inmatrix_filename1β useb = (1, ..., 1)^T2β useb = A * (1, ..., 1)^T
and then there's this one:
rhs_filenameβ the filename for the right-hand side vector
the PLAIN and Matrix Market formats are supported for rhs_filename. noted. π
π OPTIONS π
the following options are supported, and yes we're going through all of them, no skipping, that would be rude:
-ilinear solver β pick your fighter. the following options are supported for linear solver:-i {cg|1}β CG-i {bicg|2}β BiCG-i {cgs|3}β CGS-i {bicgstab|4}β BiCGSTAB-i {bicgstabl|5}β BiCGSTAB(l)-ell [2]β the degreel
-i {gpbicg|6}β GPBiCG-i {tfqmr|7}β TFQMR-i {orthomin|8}β Orthomin(m)-restart [40]β the restart valuem
-i {gmres|9}β GMRES(m)-restart [40]β the restart valuem
-i {jacobi|10}β Jacobi-i {gs|11}β Gauss-Seidel-i {sor|12}β SOR-omega [1.9]β the relaxation coefficient omega (0<omega<2)
-i {bicgsafe|13}β BiCGSafe-i {cr|14}β CR-i {bicr|15}β BiCR-i {crs|16}β CRS-i {bicrstab|17}β BiCRSTAB-i {gpbicr|18}β GPBiCR-i {bicrsafe|19}β BiCRSafe-i {fgmres|20}β FGMRES(m)-restart [40]β the restart valuem
-i {idrs|21}β IDR(s)-irestart [2]β the restart values
-i {idr1|22}β IDR(1)-i {minres|23}β MINRES-i {COCG|24}β COCG-i {COCR|25}β COCR
-ppreconditioner β the glow-up before the solve. the following options are supported for preconditioner:-p {none|0}β none-p {jacobi|1}β Jacobi-p {ilu|2}β ILU(k)-ilu_fill [0]β the fill levelk
-p {ssor|3}β SSOR-ssor_omega [1.0]β the relaxation coefficient omega (0<omega<2)
-p {hybrid|4}β Hybrid-hybrid_i [sor]β the linear solver-hybrid_maxiter [25]β the maximum number of the iterations-hybrid_tol [1.0e-3]β the convergence criterion-hybrid_omega [1.5]β the relaxation coefficient omega of the SOR (0<omega<2)-hybrid_ell [2]β the degreelof the BiCGSTAB(l)-hybrid_restart [40]β the restart values of the GMRES and Orthomin
-p {is|5}β I+S-is_alpha [1.0]β the parameter alpha of I+alpha*S(m)-is_m [3]β the parametermof I+alpha*S(m)
-p {sainv|6}β SAINV-sainv_drop [0.05]β the drop criterion
-p {saamg|7}β SA-AMG-saamg_unsym [false]β select the unsymmetric version (the matrix structure must be symmetric)-saamg_theta [0.05|0.12]β the drop criterion
-p {iluc|8}β Crout ILU-iluc_drop [0.05]β the drop criterion-iluc_rate [5.0]β the ration of maximum fill-in
-p {ilut|9}β ILUT-ilut_drop [0.05]β the drop criterion-ilut_rate [5.0]β the ration of maximum fill-in
-adds trueβ Additive Schwarz-adds_iter [1]β the number of the iteration
other options, the supporting cast, still iconic:
-maxiter [1000]β the maximum number of the iterations-tol [1.0e-12]β the convergence criterion-print [0]β the output of the residual history-print {none|0}β none-print {mem|1}β save the residual history-print {out|2}β output it to the standard output-print {all|3}β save the residual history and output it to the standard output
-scale [0]β the scaling-scale {none|0}β no scaling-scale {jacobi|1}β the Jacobi scaling-scale {symm_diag|2}β the diagonal scaling
-initx_zeros [true]β the behavior of the initial vectorx_0-initx_zero {false|0}β given values-initx_zero {true|1}β all values are set to 0
-omp_num_threads [t]β the number of the threads (trepresents the maximum number of the threads)-storage [0]β the matrix storage format-storage_block [2]β the block size of the BSR and BSC formats-f [0]β the precision of the linear solver-f {double|0}β double precision-f {quad|1}β double-double (quadruple) precision
see the Lis User Guide for full description. bestie, there's more lore than what fits in one manpage. πβ¨
π EXIT STATUS π
the following exit values are returned:
0β the process is normally terminated. we love a clean exit. πunspecifiedβ an error occurred. π
π SEE ALSO π
lis(3)esolve(1)hpcg_kernel(1)hpcg_spmvtest(1)spmvtest1(1)spmvtest2(1)spmvtest2b(1)spmvtest3(1)spmvtest3b(1)spmvtest4(1)spmvtest5(1)- http://www.ssisc.org/lis/
- http://math.nist.gov/MatrixMarket/
and that's the whole page, babe. this man page is dated 14 Sep 2017 and it lives under the man page source, so likeβ¦ when you're reading it, that's the version and date you're getting. no cap. go solve something sparse. ππ¦β¨
π¦ where this page comes from
- fedora 43: lis-bin 2.0.21-13.fc41 Β· BSD
- fedora 43: lis-bin 2.1.11-1.fc43 Β· LicenseRef-Callaway-BSD
- fedora 44: lis-bin 2.0.21-13.fc41 Β· BSD
- fedora 44: lis-bin 2.1.11-1.fc44 Β· LicenseRef-Callaway-BSD
- nixos 26.05: lis 2.1.10
- nixpkgs unstable: lis 2.1.16
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms