code: def test_supplement_a_subspace_1():
      M = DM([[1, 7, 0], [2, 3, 4]], QQ).transpose()
  
      # First supplement over QQ:
      B = supplement_a_subspace(M)
      assert B[:, :2] == M
      assert B[:, 2] == DomainMatrix.eye(3, QQ).to_dense()[:, 0]
  
      # Now supplement over FF(7):
      M = M.convert_to(FF(7))
      B = supplement_a_subspace(M)
      assert B[:, :2] == M
      # When we work mod 7, first col of M goes to [1, 0, 0],
      # so the supplementary vector cannot equal this, as it did
      # when we worked over QQ. Instead, we get the second std basis vector:
      assert B[:, 2] == DomainMatrix.eye(3, FF(7)).to_dense()[:, 1]
  
file_path: sympy/sympy/polys/numberfields/tests/test_utilities.py
imports: from sympy.abc import x
  from sympy.core.numbers import I, Rational
  from sympy.core.singleton import S
  from sympy.functions.elementary.miscellaneous import sqrt
  from sympy.polys import Poly, cyclotomic_poly
  from sympy.polys.domains import FF, QQ
  from sympy.polys.matrices import DomainMatrix, DM
  from sympy.polys.matrices.exceptions import DMRankError
  from sympy.polys.numberfields.utilities import AlgIntPowers, coeff_search, extract_fundamental_discriminant, isolate, supplement_a_subspace
  from sympy.printing.lambdarepr import IntervalPrinter
  from sympy.testing.pytest import raises
label_desc: Use image node_id 5 for calling a global function with example usage: test_supplement_a_subspace_1() without return types