Skip to content

feat(LinearAlgebra): commutative semirings satisfy strong rank condition#39161

Open
alreadydone wants to merge 1 commit into
leanprover-community:masterfrom
alreadydone:CommSemiring_StrongRankCondition
Open

feat(LinearAlgebra): commutative semirings satisfy strong rank condition#39161
alreadydone wants to merge 1 commit into
leanprover-community:masterfrom
alreadydone:CommSemiring_StrongRankCondition

Conversation

@alreadydone
Copy link
Copy Markdown
Contributor

@alreadydone alreadydone commented May 11, 2026

Co-authored-by: Aristotle Harmonic aristotle-harmonic@harmonic.fun

Thanks to ChatGPT and Gemini for converting part of Yi-Jia Tan's paper into LaTeX, which served as solutions provided to Aristotle.


Open in Gitpod

@alreadydone alreadydone added the WIP Work in progress label May 11, 2026
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 11, 2026

PR summary 0bb58f289c

Import changes for modified files

No significant changes to the import graph

Import changes for all files
Files Import difference
Mathlib.LinearAlgebra.Matrix.Nonsingular (new file) 1410

Declarations diff

+ Nonsingular
+ adjp_diag_last_eq_detp_sub
+ adjp_last_col_eq
+ adjp_mul_apply_eq
+ adjp_mul_apply_ne
+ augmented_good
+ detp_eq_of_eq_row
+ detp_eq_submatrix_equiv
+ detp_eq_zero_of_exists_row_eq_zero
+ detp_laplace_last_row
+ exists_mulVec_eq_of_bad_entry'
+ finNeLastEquiv
+ instance [Nontrivial R] : StrongRankCondition R
+ linearIndependent_col_iff
+ linearIndependent_col_of_nonsingular
+ nonsingular_iff_det_mem_nonZeroDivisors
+ nonsingular_of_linearIndependent
+ nonsingular_of_linearIndependent_col
+ not_linearIndependent_of_bad_entry
+ not_linearIndependent_of_smul_eq
+ witness_from_bad_submatrix

You can run this locally as follows
## from your `mathlib4` directory:
git clone https://github.com/leanprover-community/mathlib-ci.git ../mathlib-ci

## summary with just the declaration names:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh <optional_commit>

## more verbose report:
../mathlib-ci/scripts/pr_summary/declarations_diff.sh long <optional_commit>

The doc-module for scripts/pr_summary/declarations_diff.sh in the mathlib-ci repository contains some details about this script.


No changes to strong technical debt.
No changes to weak technical debt.

@github-actions github-actions Bot added the t-algebra Algebra (groups, rings, fields, etc) label May 11, 2026
@alreadydone alreadydone force-pushed the CommSemiring_StrongRankCondition branch 2 times, most recently from 9bed5f1 to 7c03fcc Compare May 11, 2026 02:36
@alreadydone alreadydone force-pushed the CommSemiring_StrongRankCondition branch from 7c03fcc to fb00d31 Compare May 11, 2026 03:21

* `Matrix.Nonsingular`: if `R` is a commutative semiring, a matrix `A` in `Mₙ(R)` is called
nonsingular if `a|A|⁺ + b|A|⁻ = b|A|⁻ + a|A|⁺` implies `a = b` for `a, b : R`.
`|A|⁺` and `|A|⁻` are `A.detp 1` and `A.detp (-1)` respectively in mathlib (`Matrix.detp`).
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
`|A|⁺` and `|A|⁻` are `A.detp 1` and `A.detp (-1)` respectively in mathlib (`Matrix.detp`).
`|A|⁺` and `|A|⁻` are `A.detp 1` and `A.detp (-1)` respectively (`Matrix.detp`).

cancellative addition is nonsingular, then its columns are linearly independent.
Corollary 3.2(2) of [Tan2016].

* `Matrix.instStrongRankConditionOfNontrivial`: a commutative semiring satisfies the strong rank
Copy link
Copy Markdown
Collaborator

@SnirBroshi SnirBroshi May 11, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since you're referencing the instance by name, I think it should be explicitly named rather than relying on the naming algorithm to be backwards compatible.

@alreadydone alreadydone added the LLM-generated PRs with substantial input from LLMs - review accordingly label May 11, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

LLM-generated PRs with substantial input from LLMs - review accordingly t-algebra Algebra (groups, rings, fields, etc) WIP Work in progress

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants