"Source: Text/Ring/RngSlope.text";
"Line: 1064";
"Date: Fri Sep 26 12:10:11 2025";
"Main: Fri Sep 26 14:29:19 2025";
// original file: Text/Ring/RngSlope.text, line: 1064
// Example: H57E5 ()
print "Example: H57E5";
ei := GetEchoInput();
SetEchoInput(true);
S<u> := SpRing (pAdicField (5, 25), 1/2); // slope 1/2
A := SpSpace (S, 3);
A.1;
M := SpMatrix (2, 3, [ S | 5*u,5,u^2, 1/5,u^3,u ]);
B := SpSpace (M); assert Dimension(B) eq 2;
LeadingTerms(BasisMatrix(B));
B eq SpSpace (VerticalJoin (M, M)); // also gives inclusion
assert $1;
A meet B eq B;
assert $1;
Image(M) eq B; // by definition
assert $1;
IsConsistent (M, A.1);
assert not $1;
IsConsistent (M, B.1);
assert $1;
SpSpace([B.1]) + SpSpace([B.2]) eq B;
assert $1;
SpSpace([B.1]) + SpSpace([u * B.2]) eq B; // u does not invert
assert not $1;
SpSpace([1/5 * B.1]) + SpSpace([5 * B.2]) eq B;
assert $1;
sub<B|[B.1+B.2]> + sub<B|[B.2-B.1]> eq sub<B|[B.1,B.2]>;
assert $1;
SetEchoInput(ei);
