Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit e09ac77

Browse files
fixing doctests in 2010年12月11日-Nikolaus
1 parent a653c1c commit e09ac77

File tree

1 file changed

+40
-30
lines changed

1 file changed

+40
-30
lines changed

‎2010年12月11日-Nikolaus.rst‎

Lines changed: 40 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,8 @@ Nikolaus Conference 2010, Aachen: Sage-Combinat demo
1111

1212
::
1313

14-
sage: %hide
15-
sage: pretty_print_default(False)
14+
sage: %hide # not tested
15+
sage: pretty_print_default(False) # not tested
1616

1717

1818
Tableaux and the like
@@ -22,6 +22,7 @@ Tableaux and the like
2222

2323
sage: s = Permutation([5,3,2,6,4,8,9,7,1])
2424
sage: s
25+
[5, 3, 2, 6, 4, 8, 9, 7, 1]
2526

2627
sage: (p,q) = s.robinson_schensted()
2728
sage: p.pp()
@@ -39,6 +40,7 @@ Counting & the like
3940
::
4041

4142
sage: Partitions(100000).cardinality()
43+
27493510569...
4244

4345
Species::
4446

@@ -65,11 +67,12 @@ Lattice points of polytopes
6567

6668
::
6769

68-
sage: A=random_matrix(ZZ,3,6,x=7)
69-
sage: L=LatticePolytope(A)
70+
sage: A = random_matrix(ZZ,6,3,x=7)
71+
sage: L = LatticePolytope(A)
7072
sage: L.plot3d()
73+
Graphics3d Object
7174

72-
sage: L.npoints() # should be cardinality!
75+
sage: L.npoints() # should be cardinality! # random
7376
28
7477

7578
This example used PALP and J-mol
@@ -80,7 +83,8 @@ Graphs up to an isomorphism
8083
::
8184

8285
sage: show(graphs(5, lambda G: G.size() <= 4))
83-
86+
<html>...
87+
8488
Symmetric functions
8589
+++++++++++++++++++
8690

@@ -89,69 +93,76 @@ Usual bases::
8993
sage: Sym = SymmetricFunctions(QQ); Sym
9094
Symmetric Functions over Rational Field
9195
sage: Sym.inject_shorthands()
92-
96+
Defining ...
97+
9398
sage: m(( ( h[2,1] * ( 1 + 3 * p[2,1]) ) + s[2](s[3])))
99+
3*m[1, 1, 1] + ...
94100

95101
Macdonald polynomials::
96102

97-
sage: J = MacdonaldPolynomialsJ(QQ)
98-
sage: P = MacdonaldPolynomialsP(QQ)
99-
sage: Q = MacdonaldPolynomialsQ(QQ)
103+
sage: Sym = SymmetricFunctions(FractionField(QQ['q','t']))
104+
sage: J = Sym.macdonald().J()
105+
sage: P = Sym.macdonald().P()
106+
sage: Q = Sym.macdonald().Q()
100107
sage: J
101-
Macdonald polynomials in the J basis over Fraction Field of Multivariate Polynomial Ring in q, t over Rational Field
108+
Symmetric Functions over Fraction Field of Multivariate Polynomial Ring in q, t over Rational Field in the Macdonald J basis
109+
102110
sage: P(J[2,2] + 3 * Q[3,1])
111+
(...)*McdP[2, 2] + ...
103112

104113
Root systems
105114
++++++++++++
106115

107116
::
108117

109118
sage: L = RootSystem(['A',2,1]).weight_space()
110-
sage: L.plot(size=[[-1..1],[-1..1]],alcovewalks=[[0,2,0,1,2,1,2,0,2,1]])
119+
sage: L.plot(alcove_walk=[0,2,0,1,2,1,2,0,2,1])
120+
Graphics object consisting of 148 graphics primitives
111121

112122
sage: W = WeylGroup(["B", 3])
113123
sage: W.cayley_graph(side = "left").plot3d(color_by_label = True)
114-
124+
Graphics3d Object
125+
115126
GAP at work
116127
+++++++++++
117128

118129
::
119130

131+
sage: W = WeylGroup(["B", 3])
120132
sage: print(W.character_table()) # Thanks GAP!
121133
CT1
122-
123-
2 4 4 3 3 4 3 1 1 3 4
124-
3 1 . . . . . 1 1 . 1
125-
126-
1a 2a 2b 4a 2c 2d 6a 3a 4b 2e
127-
134+
...
128135
X.1 1 1 1 1 1 1 1 1 1 1
129136
X.2 1 1 1 -1 -1 -1 -1 1 1 -1
130137
X.3 1 1 -1 -1 1 -1 1 1 -1 1
131138
X.4 1 1 -1 1 -1 1 -1 1 -1 -1
132139
X.5 2 2 . . -2 . 1 -1 . -2
133140
X.6 2 2 . . 2 . -1 -1 . 2
134-
X.7 3 -1 1 1 1 -1 . . -1 -3
135-
X.8 3 -1 -1 -1 1 1 . . 1 -3
136-
X.9 3 -1 -1 1 -1 -1 . . 1 3
137-
X.10 3 -1 1 -1 -1 1 . . -1 3
141+
X.7 3 -1 -1 1 -1 -1 . . 1 3
142+
X.8 3 -1 1 1 1 -1 . . -1 -3
143+
X.9 3 -1 1 -1 -1 1 . . -1 3
144+
X.10 3 -1 -1 -1 1 1 . . 1 -3
138145

139146
sage: type(W.character_table())
147+
<class 'sage.interfaces.interface.AsciiArtString'>
140148

141-
sage: G = gap(W); G
149+
sage: G = W.gap(); G
150+
<matrix group of size 48 with 3 generators>
142151

143-
sage: G.Ch
152+
sage: G.Ch # not tested
144153

145154
sage: T = G.CharacterTable(); T
155+
CharacterTable( <matrix group of size 48 with 3 generators> )
146156

147-
sage: T.Irr()[10,10]
157+
sage: T.Irr()[4,4]
158+
-2
148159

149160
Coxeter3 at work
150161
++++++++++++++++
151162

152163
::
153164

154-
sage: W3 = CoxeterGroup(W, implementation="coxeter3")
165+
sage: W3 = CoxeterGroup(["B", 3], implementation="coxeter3")
155166
sage: KL = matrix([ [ W3.kazhdan_lusztig_polynomial(u,v) if u.bruhat_le(v) else 0 for u in W3 ]
156167
....: for v in W3])
157168
sage: show(KL)
@@ -170,10 +181,9 @@ Crystals
170181

171182
::
172183

173-
sage: latex.jsmath_avoid_list(['tikzpicture'])
174-
sage: K = KirillovReshetikhinCrystal(['A',3,1], 2,2)
184+
sage: K = crystals.KirillovReshetikhin(['A',3,1], 2,2)
175185
sage: G = K.digraph()
176-
sage: G.set_latex_options(format = "dot2tex", edge_labels = True, color_by_label = {0:"black", 1:"blue", 2:"red", 3:"green"}, edge_options = lambda (u,v,label):({"backward":label ==0}))
186+
sage: G.set_latex_options(format = "dot2tex", edge_labels = True, color_by_label = {0:"black", 1:"blue", 2:"red", 3:"green"}, edge_options=lambda u_v_label:({"backward": u_v_label[2] == 0}))
177187
sage: view(G, viewer="pdf", tightpage=True)
178188

179189
* :ref:`demo-GAP3-Semigroupe`

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /