Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/sage/cpython/dict_del_by_value.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -147,7 +147,7 @@ def test_del_dictitem_by_exact_value(D, value, h):
- ``h`` -- the hash of the key under which to find ``value`` in ``D``

The underlying cdef function deletes an item from ``D`` that is in the
hash bucket determined by ``h`` and whose value is identic with
hash bucket determined by ``h`` and whose value is identical with
``value``. Of course, this only makes sense if the pairs ``(h, value)``
corresponding to items in ``D`` are pair-wise distinct.

Expand Down
12 changes: 6 additions & 6 deletions src/sage/geometry/lattice_polytope.py
Original file line number Diff line number Diff line change
Expand Up @@ -450,8 +450,8 @@ def ReflexivePolytopes(dim):
if _rp[dim] is None:
db = DatabaseReflexivePolytopes()
rp = read_all_polytopes(
os.path.join(os.path.dirname(db.absolute_filename()),
f'reflexive_polytopes_{dim}d'))
os.path.join(os.path.dirname(db.absolute_filename()),
f'reflexive_polytopes_{dim}d'))
for n, p in enumerate(rp):
# Data files have normal form of reflexive polytopes
p.normal_form.set_cache(p._vertices)
Expand Down Expand Up @@ -760,7 +760,7 @@ def _compute_embedding(self) -> None:
# Absolute value helps to keep normals "inner"
self._dual_embedding_scale = abs(basis.det())
dualbasis = matrix(ZZ, self._dual_embedding_scale * basis.inverse())
self._dual_embedding_matrix = dualbasis.submatrix(0,0,M.ncols())
self._dual_embedding_matrix = dualbasis.submatrix(0, 0, M.ncols())

def _compute_facets(self):
r"""
Expand Down Expand Up @@ -4008,7 +4008,7 @@ def skeleton_show(self, normal=None):
raise NotImplementedError("skeleton view is implemented only in 3-d space")
if normal is None:
normal = [ZZ.random_element(20),ZZ.random_element(20),ZZ.random_element(20)]
normal = matrix(QQ,3,1,list(normal))
normal = matrix(QQ, 3, 1, list(normal))
projectionm = normal.kernel().basis_matrix()
positions = dict(enumerate([list(c) for c in (projectionm*self.points()).columns(copy=False)]))
self.skeleton().show(pos=positions)
Expand Down Expand Up @@ -4311,7 +4311,7 @@ def __init__(self, data, Delta_polar, check=True):
"""
if check and not Delta_polar.is_reflexive():
raise ValueError("nef-partitions can be constructed for reflexive "
"polytopes ony!")
"polytopes only!")
self._vertex_to_part = tuple(int(el) for el in data)
self._nparts = max(self._vertex_to_part) + 1
self._Delta_polar = Delta_polar
Expand Down Expand Up @@ -5646,7 +5646,7 @@ def positive_integer_relations(points):
# Use the new relation to remove negative entries in non-pivot columns
for i in range(n_nonpivots):
for j in range(n):
coef = relations[j,nonpivots[i]]
coef = relations[j, nonpivots[i]]
if coef < 0:
relations.add_multiple_of_row(j, n + i, -coef)
# Get a new basis
Expand Down
4 changes: 2 additions & 2 deletions src/sage/graphs/generators/trees.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -559,9 +559,9 @@ cdef class TreeIterator:
sig_free(self.l)
sig_free(self.current_level_sequence)

def __str__(self):
def __str__(self) -> str:
r"""
Return a string representaiton of ``self``.
Return a string representation of ``self``.

EXAMPLES::

Expand Down
2 changes: 1 addition & 1 deletion src/sage/graphs/graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -2937,7 +2937,7 @@ def is_chordal_bipartite(self, certificate=False):
(:meth:`~sage.graphs.bipartite_graph.BipartiteGraph.reduced_adjacency_matrix`)
of a bipartite graph has no cycle submatrix if and only if the graph is
chordal bipartite, where cycle submatrix is 0-1 `n \times n` matrix `n \geq 3`
with exactly two 1's in each row and column and no proper submatrix satsify
with exactly two 1's in each row and column and no proper submatrix satisfy
this property.
* A doubly lexical ordering
Expand Down
10 changes: 5 additions & 5 deletions src/sage/graphs/matching_covered_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -1456,7 +1456,7 @@ def add_edges(self, edges, loops=False):
M.add_edges(self.get_matching())

# Check if M is a perfect matching of the resulting graph
if (G.order() != 2*M.size()):
if (G.order() != 2 * M.size()):
M = None

self.__init__(data=G, matching=M)
Expand Down Expand Up @@ -1974,7 +1974,7 @@ def delete_vertices(self, vertices):
# must be a valid perfect matching of the resulting graph obtained
# after the removal of the vertices

if (G.order() != 2*M.size()):
if (G.order() != 2 * M.size()):
M = None

self.__init__(data=G, matching=M)
Expand Down Expand Up @@ -2043,7 +2043,7 @@ def maximal_barrier(self, vertex):

And in order to find the vertices that do not lie in the maximal
barrier containing the provided vertex in linear time we take
inspiration of the `M` alternating tree seach method [LR2004]_.
inspiration of the `M` alternating tree search method [LR2004]_.

INPUT:

Expand Down Expand Up @@ -2825,8 +2825,8 @@ def dfs(x, visited, neighbor_iterator):

# Compute the nontrivial tight cut C := ∂(Y)
C = [(x, y, w) if x in X else (y, x, w)
for x, y, w in self.edge_iterator(sort_vertices=True)
if (x in X) ^ (y in X)]
for x, y, w in self.edge_iterator(sort_vertices=True)
if (x in X) ^ (y in X)]

# Obtain the barrier Z
Z = None
Expand Down
2 changes: 1 addition & 1 deletion src/sage/interfaces/khoca.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
r"""
Interface to Khoca

Khoca is computer program writen by Lukas Lewark to calculate sl(N)-homology
Khoca is computer program written by Lukas Lewark to calculate sl(N)-homology
of knots and links. It calculates the following:

* Khovanov sl(2)-homology of arbitrary links, given as a braid or in PD code.
Expand Down
2 changes: 1 addition & 1 deletion src/sage/modules/free_module.py
Original file line number Diff line number Diff line change
Expand Up @@ -3175,7 +3175,7 @@ def pseudohom(self, f, twist, codomain=None, side="left"):

- ``twist`` -- the twisting morphism or the twisting derivation
(if a derivation is given, the corresponding morphism `\theta`
is automatically infered;
is automatically inferred;
see also :class:`sage.rings.polynomial.ore_polynomial_ring.OrePolynomialRing`)

- ``codomain`` -- (default: ``None``) the codomain of the pseudo
Expand Down
16 changes: 8 additions & 8 deletions src/sage/rings/function_field/function_field_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -73,13 +73,13 @@ def T(F):
# https://github.com/pytest-dev/pytest/issues/349
#
pairs = [("J", None),
("K", 16),
("L", 2),
("M", 1),
("N", 1),
("O", None),
("T", None),
("S", 8)]
("K", 16),
("L", 2),
("M", 1),
("N", 1),
("O", None),
("T", None),
("S", 8)]


@pytest.mark.parametrize("ff,max_runs", pairs)
Expand All @@ -95,7 +95,7 @@ def test_function_field_testsuite(ff, max_runs, request) -> None:
The inputs are essentially all fixtures.

- ``ff`` -- string; a function field fixture name
- ``max_runs`` -- integer; the maxmimum number of times to
- ``max_runs`` -- integer; the maximum number of times to
repeat the test suite
- ``request`` -- fixture; a pytest built-in

Expand Down
2 changes: 1 addition & 1 deletion src/sage/rings/polynomial/polydict.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ cdef class PolyDict:
Data structure for multivariate polynomials.

A PolyDict holds a dictionary all of whose keys are :class:`ETuple` and
whose values are coefficients on which it is implicitely assumed that
whose values are coefficients on which it is implicitly assumed that
arithmetic operations can be performed.

No arithmetic operation on :class:`PolyDict` clear zero coefficients as of
Expand Down
2 changes: 1 addition & 1 deletion src/sage/rings/polynomial/polynomial_element.pyx
Original file line number Diff line number Diff line change
Expand Up @@ -2260,7 +2260,7 @@ cdef class Polynomial(CommutativePolynomial):
else:
# Compute the trace of T with field of order 2^k
# sum T^(2^i) for i in range (degree * k)
# We use repeated squaring to avoid redundent multiplications
# We use repeated squaring to avoid redundant multiplications
C, TT = T, T
for _ in range(degree * self.base_ring().degree() - 1):
TT = TT * TT % self
Expand Down
4 changes: 2 additions & 2 deletions src/sage/schemes/curves/zariski_vankampen.py
Original file line number Diff line number Diff line change
Expand Up @@ -295,7 +295,7 @@ def orient_circuit(circuit, convex=False, precision=53, verbose=False):
OUTPUT:

The same circuit if it goes counterclockwise, and its reversed otherwise,
given as the ordered list of vertices with identic extremities.
given as the ordered list of vertices with identical extremities.

EXAMPLES::

Expand Down Expand Up @@ -1036,7 +1036,7 @@ def geometric_basis(G, E, EC0, p, dual_graph, vertical_regions={}) -> list:
for i, v in enumerate(cutpath):
if i > 0 and v in EC:
r = v
cutpath = cutpath[:i+1]
cutpath = cutpath[:i + 1]
break
qi = EC.index(q)
ri = EC.index(r)
Expand Down
Loading