Skip to content

Aug improvement#1745

Merged
sangwinc merged 3 commits into
masterfrom
aug_improvement
May 6, 2026
Merged

Aug improvement#1745
sangwinc merged 3 commits into
masterfrom
aug_improvement

Conversation

@LukeLongworth

Copy link
Copy Markdown
Collaborator

Improvements to aug following suggestions from Marc Peterfi. The function behaves as it previously did when given a single matrix (that is, it will insert a vertical bar before the final column), but when given two or more matrices as arguments it will concatenate them with vertical bars between each.

The original use case is to generate worked solutions for matrix inversion or similar, e.g. aug(A, ident(3)) → aug(rowop(A,2,1,A[2,1]/A[1,1]), rowop(ident(3),2,1,A[2,1]/A[1,1]) but could be used for more.

aug(addcol(A,b)) and aug(A,b) are identical.

Existing test cases will fail only because the vertical bar is now generated as a closing bracket instead of an opening one. This looks nicer, so I am treating this as a feature instead of a bug.

My apologies for two separate pull requests in quick succession!

Improvements to `aug` following suggestions from Marc Peterfi. The function behaves as it previously did when given a single matrix (that is, it will insert a vertical bar before the final column), but when given two or more matrices as arguments it will concatenate them with vertical bars between each. 

The original use case is to generate worked solutions for matrix inversion or similar, e.g. aug(A, ident(3)) → aug(rowop(A,2,1,A[2,1]/A[1,1]), rowop(ident(3),2,1,A[2,1]/A[1,1]) but could be used for more. 

aug(addcol(A,b)) and aug(A,b) are identical. 

Existing test cases will fail only because the vertical bar is now generated as a closing bracket instead of an opening one. This looks nicer, so I am treating this as a feature instead of a bug.
Adding and updating test cases for new aug functionality
Updated docs to reflect expanded aug functionality
@sangwinc

sangwinc commented May 6, 2026

Copy link
Copy Markdown
Member

Thanks @LukeLongworth the aug_matrix function looks very useful.

@sangwinc sangwinc merged commit d124dc4 into master May 6, 2026
10 checks passed
@sangwinc sangwinc deleted the aug_improvement branch May 6, 2026 09:12
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants