-
-
Notifications
You must be signed in to change notification settings - Fork 516
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
about no empty final lines URL: https://trac.sagemath.org/34290 Reported by: chapoton Ticket author(s): Frédéric Chapoton Reviewer(s): Travis Scrimshaw
- Loading branch information
Showing
35 changed files
with
37 additions
and
96 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,6 @@ | |
- Eero Hakavuori (2018-08-29): initial version | ||
""" | ||
|
||
# **************************************************************************** | ||
# Copyright (C) 2018 Eero Hakavuori <[email protected]> | ||
# | ||
|
@@ -15,7 +14,6 @@ | |
# (at your option) any later version. | ||
# https://www.gnu.org/licenses/ | ||
# **************************************************************************** | ||
|
||
from sage.algebras.lie_algebras.lie_algebra_element import LieSubalgebraElementWrapper | ||
from sage.categories.lie_algebras import LieAlgebras | ||
from sage.categories.homset import Hom | ||
|
@@ -975,4 +973,3 @@ def adjoint_matrix(self, sparse=False): | |
return matrix(self.base_ring(), | ||
[M.coordinate_vector(P.bracket(self, b).to_vector(sparse=sparse)) | ||
for b in basis], sparse=sparse).transpose() | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -3,21 +3,18 @@ | |
This is all.py (load all sage functions) plus set-up for the Sage commandline. | ||
""" | ||
|
||
#***************************************************************************** | ||
# **************************************************************************** | ||
# Copyright (C) 2007 William Stein <[email protected]> | ||
# | ||
# This program is free software: you can redistribute it and/or modify | ||
# it under the terms of the GNU General Public License as published by | ||
# the Free Software Foundation, either version 2 of the License, or | ||
# (at your option) any later version. | ||
# http://www.gnu.org/licenses/ | ||
#***************************************************************************** | ||
|
||
# https://www.gnu.org/licenses/ | ||
# **************************************************************************** | ||
sage_mode = 'cmdline' | ||
|
||
from sage.all import * | ||
from sage.calculus.predefined import x | ||
|
||
sage.misc.session.init() | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -48,4 +48,3 @@ | |
X = _var('X') | ||
Y = _var('Y') | ||
Z = _var('Z') | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,18 @@ | ||
""" | ||
Classical Ciphers | ||
""" | ||
|
||
#***************************************************************************** | ||
# **************************************************************************** | ||
# Copyright (C) 2007 David Kohel <[email protected]> | ||
# | ||
# Distributed under the terms of the GNU General Public License (GPL) | ||
# | ||
# http://www.gnu.org/licenses/ | ||
#***************************************************************************** | ||
|
||
# https://www.gnu.org/licenses/ | ||
# **************************************************************************** | ||
from .cipher import SymmetricKeyCipher | ||
from sage.monoids.string_monoid_element import StringMonoidElement | ||
from sage.modules.free_module import FreeModule | ||
|
||
|
||
class AffineCipher(SymmetricKeyCipher): | ||
r""" | ||
Affine cipher class. This is the class that does the actual work of | ||
|
@@ -574,7 +573,3 @@ def inverse(self): | |
E = self.parent() | ||
K = E.inverse_key(self.key()) | ||
return E(K) | ||
|
||
|
||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -2,11 +2,12 @@ | |
Abstract base class for generators of polynomial systems | ||
AUTHOR: | ||
Martin Albrecht <[email protected]> | ||
""" | ||
Martin Albrecht <[email protected]> | ||
""" | ||
from sage.structure.sage_object import SageObject | ||
|
||
|
||
class MPolynomialSystemGenerator(SageObject): | ||
""" | ||
Abstract base class for generators of polynomial systems. | ||
|
@@ -26,8 +27,7 @@ def __getattr__(self, attr): | |
if attr == "R": | ||
self.R = self.ring() | ||
return self.R | ||
else: | ||
raise AttributeError("'%s' object has no attribute '%s'"%(self.__class__,attr)) | ||
raise AttributeError("'%s' object has no attribute '%s'" % (self.__class__,attr)) | ||
|
||
def varformatstr(self, name): | ||
""" | ||
|
@@ -196,4 +196,3 @@ def random_element(self): | |
NotImplementedError | ||
""" | ||
raise NotImplementedError | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -276,4 +276,3 @@ def simulations(self, n, k=1): | |
## OUTPUT: | ||
## m0, sigma, gamma_kbar, b | ||
## """ | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,6 @@ | ||
""" | ||
Parser For gambit And lrs Nash Equilibria | ||
""" | ||
|
||
# **************************************************************************** | ||
# Copyright (C) 2014 James Campbell [email protected] | ||
# 2015 Vincent Knight | ||
|
@@ -13,6 +12,7 @@ | |
# https://www.gnu.org/licenses/ | ||
# **************************************************************************** | ||
|
||
|
||
class Parser(): | ||
r""" | ||
A class for parsing the outputs of different algorithms called in other | ||
|
@@ -298,4 +298,3 @@ def format_gambit(self, gambit_game): | |
nice_stuff.append(profile) | ||
|
||
return nice_stuff | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -12,15 +12,14 @@ | |
- John H. Palmieri (2015-09) | ||
""" | ||
|
||
######################################################################## | ||
# Copyright (C) 2015 John H. Palmieri <[email protected]> | ||
# | ||
# Distributed under the terms of the GNU General Public License (GPL) | ||
# as published by the Free Software Foundation; either version 2 of | ||
# the License, or (at your option) any later version. | ||
# | ||
# http://www.gnu.org/licenses/ | ||
# https://www.gnu.org/licenses/ | ||
######################################################################## | ||
|
||
# TODO: cythonize this. | ||
|
@@ -590,4 +589,3 @@ def conditionally_sparse(m): | |
iota = ChainComplexMorphism(iota_data, M, C) | ||
phi = ChainContraction(phi_data, pi, iota) | ||
return phi, M | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,7 +5,6 @@ | |
group that prints itself in a way that is suitable for homology | ||
groups. | ||
""" | ||
|
||
######################################################################## | ||
# Copyright (C) 2013 John H. Palmieri <[email protected]> | ||
# Volker Braun <[email protected]> | ||
|
@@ -14,7 +13,7 @@ | |
# as published by the Free Software Foundation; either version 2 of | ||
# the License, or (at your option) any later version. | ||
# | ||
# http://www.gnu.org/licenses/ | ||
# https://www.gnu.org/licenses/ | ||
######################################################################## | ||
|
||
from sage.modules.free_module import VectorSpace | ||
|
@@ -182,6 +181,4 @@ def HomologyGroup(n, base_ring, invfac=None): | |
invfac = [0] * (n - len(invfac)) + invfac | ||
elif len(invfac) > n: | ||
raise ValueError("invfac (={}) must have length n (={})".format(invfac, n)) | ||
M = HomologyGroup_class(n, invfac) | ||
return M | ||
|
||
return HomologyGroup_class(n, invfac) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -14,7 +14,6 @@ | |
- John H. Palmieri, Travis Scrimshaw (2015-09) | ||
""" | ||
|
||
######################################################################## | ||
# Copyright (C) 2015 John H. Palmieri <[email protected]> | ||
# Travis Scrimshaw <tscrimsh at umn.edu> | ||
|
@@ -23,7 +22,7 @@ | |
# as published by the Free Software Foundation; either version 2 of | ||
# the License, or (at your option) any later version. | ||
# | ||
# http://www.gnu.org/licenses/ | ||
# https://www.gnu.org/licenses/ | ||
######################################################################## | ||
|
||
from sage.misc.cachefunc import cached_method | ||
|
@@ -871,4 +870,3 @@ def sum_indices(k, i_k_plus_one, S_k_plus_one): | |
return [[S_k]] | ||
return [[i_k] + l for i_k in range(S_k, i_k_plus_one) | ||
for l in sum_indices(k-1, i_k, S_k)] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,15 +5,14 @@ | |
with the differentials thought of as matrices. This module contains | ||
some utility functions for this purpose. | ||
""" | ||
|
||
######################################################################## | ||
# Copyright (C) 2013 John H. Palmieri <[email protected]> | ||
# | ||
# Distributed under the terms of the GNU General Public License (GPL) | ||
# as published by the Free Software Foundation; either version 2 of | ||
# the License, or (at your option) any later version. | ||
# | ||
# http://www.gnu.org/licenses/ | ||
# https://www.gnu.org/licenses/ | ||
######################################################################## | ||
|
||
# TODO: this module is a clear candidate for cythonizing. Need to | ||
|
@@ -203,4 +202,3 @@ def dhsw_snf(mat, verbose=False): | |
if len(ed) < rows: | ||
return ed + [0]*(rows - len(ed)) | ||
return ed[:rows] | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -690,4 +690,3 @@ def __doctest_cleanup(): | |
""" | ||
import sage.interfaces.quit | ||
sage.interfaces.quit.expect_quitall() | ||
|
Oops, something went wrong.