1 | initial version |

I am not sure to understand your request, but you can try:

```
sage: index, deg = rankrep(3)
sage: index
['A8(fw[1])', 'A8(fw[8])']
sage: deg
[[2],
[3, 3],
[4, 6, 4],
[5, 10, 10, 5],
[6, 15, 20, 15, 6],
[7, 21, 35, 35, 21, 7],
[8, 28, 56, 70, 56, 28, 8],
[9, 36, 84, 126, 126, 84, 36, 9],
[10, 45, 120, 210, 252, 210, 120, 45, 10]]
sage: deg[3]
[5, 10, 10, 5]
```

2 | No.2 Revision |

I am not sure to understand your request, but you can ~~try:~~modify your last line by:

```
return index, deg, L
```

And then play with it:

`sage: index, `~~deg ~~deg, L = rankrep(3)
sage: index
['A8(fw[1])', 'A8(fw[8])']
sage: deg
[[2],
[3, 3],
[4, 6, 4],
[5, 10, 10, 5],
[6, 15, 20, 15, 6],
[7, 21, 35, 35, 21, 7],
[8, 28, 56, 70, 56, 28, 8],
[9, 36, 84, 126, 126, 84, 36, 9],
[10, 45, 120, 210, 252, 210, 120, 45, 10]]
sage: deg[3]
[5, 10, 10, 5]
sage: L
[(1, 0, 0, 0, 0, 0, 0, 0, 0), (1, 1, 1, 1, 1, 1, 1, 1, 0)]

3 | No.3 Revision |

I am not sure to understand your request, but you can modify ~~your ~~the last line of your function to return `L`

as well by:

```
return index, deg, L
```

And then play with it:

```
sage: index, deg, L = rankrep(3)
sage: index
['A8(fw[1])', 'A8(fw[8])']
sage: deg
[[2],
[3, 3],
[4, 6, 4],
[5, 10, 10, 5],
[6, 15, 20, 15, 6],
[7, 21, 35, 35, 21, 7],
[8, 28, 56, 70, 56, 28, 8],
[9, 36, 84, 126, 126, 84, 36, 9],
[10, 45, 120, 210, 252, 210, 120, 45, 10]]
sage: deg[3]
[5, 10, 10, 5]
sage: L
[(1, 0, 0, 0, 0, 0, 0, 0, 0), (1, 1, 1, 1, 1, 1, 1, 1, 0)]
```

4 | No.4 Revision |

I am not sure to understand your request, but you can modify the last line of your function to return `L`

as well by:

```
return index, deg, L
```

And then play with it:

```
sage: index, deg, L = rankrep(3)
sage: index
['A8(fw[1])', 'A8(fw[8])']
sage: deg
[[2],
[3, 3],
[4, 6, 4],
[5, 10, 10, 5],
[6, 15, 20, 15, 6],
[7, 21, 35, 35, 21, 7],
[8, 28, 56, 70, 56, 28, 8],
[9, 36, 84, 126, 126, 84, 36, 9],
[10, 45, 120, 210, 252, 210, 120, 45, 10]]
sage: deg[3]
[5, 10, 10, 5]
sage: L
[(1, 0, 0, 0, 0, 0, 0, 0, 0), (1, 1, 1, 1, 1, 1, 1, 1, 0)]
```

To transform the elements of `L`

to a list of vectors, you can:

```
sage: w = []
sage: for i in L:
....: w.append(i.to_vector())
....:
sage: w[0]
(1, 0, 0, 0, 0, 0, 0, 0, 0)
sage: w[1]
(1, 1, 1, 1, 1, 1, 1, 1, 0)
```

5 | No.5 Revision |

I am not sure to understand your request, but you can modify the last line of your function to return `L`

as well by:

```
return index, deg, L
```

And then play with it:

```
sage: index, deg, L = rankrep(3)
sage: index
['A8(fw[1])', 'A8(fw[8])']
sage: deg
[[2],
[3, 3],
[4, 6, 4],
[5, 10, 10, 5],
[6, 15, 20, 15, 6],
[7, 21, 35, 35, 21, 7],
[8, 28, 56, 70, 56, 28, 8],
[9, 36, 84, 126, 126, 84, 36, 9],
[10, 45, 120, 210, 252, 210, 120, 45, 10]]
sage: deg[3]
[5, 10, 10, 5]
sage: L
[(1, 0, 0, 0, 0, 0, 0, 0, 0), (1, 1, 1, 1, 1, 1, 1, 1, 0)]
```

To transform the elements of `L`

to a list of vectors, you can:

`sage: w = `~~[]
sage: ~~[i.to_vector() for i in ~~L:
....: w.append(i.to_vector())
....:
~~L]
sage: w[0]
(1, 0, 0, 0, 0, 0, 0, 0, 0)
sage: w[1]
(1, 1, 1, 1, 1, 1, 1, 1, 0)

Copyright Sage, 2010. Some rights reserved under creative commons license. Content on this site is licensed under a Creative Commons Attribution Share Alike 3.0 license.