# Quantum binomials

What is the difference between `q.analogues.q_binomial(n,k)`

and `gaussian_binomial(n,k)`

?
Superficially they seem to be the same.

Quantum binomials

`q.analogues.q_binomial(n,k)`

and `gaussian_binomial(n,k)`

?
Superficially they seem to be the same.

3

gaussian_binomial is faster, for one:

```
sage: %timeit a=q_analogues.q_binomial(20,10)
25 loops, best of 3: 8.45 ms per loop
sage: %timeit a=gaussian_binomial(20,10)
625 loops, best of 3: 1.52 ms per loop
```

Looking at the code makes me think that `gaussian_binomial`

is strictly better than `q_binomial`

, and the latter should be made an alias for the former. But perhaps I'm missing something.

What is this q_analogues? For people who want to try the above, you have to first type sage: import sage.combinat.q_analogues as q_analogues

Oops, yes, i forgot to include the import statement. Thanks, William.

Asked: **
2010-08-19 10:14:06 -0600
**

Seen: **192 times**

Last updated: **Jan 03 '11**

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.

What is "qbinomial" or "q.analgoues"? I can't find anything like that. Can you post a complete example to make this question easier to answer?

OK, I was thrown off by underscores getting rendered in a weird way.