# Simple counting on restricted n-ary k-tuples

I have some simple counting problems, for example, how many n-ary k-tuples, i.e. $(v_0,v_1,\ldots, v_k)$ with $0\le v_i < n$, are there which have $v_0=1$, and $m$ non-zero coordinates.

What sort of functionality is there is Sage or other computer algebra systems for answering such questions for general $n,k$ and $m$?

edit retag close merge delete

Sort by ยป oldest newest most voted

I'm not quite sure how to interpret your question, but do you mean integer vectors?

more

they are a restricted class of integer vectors, since every vector would have the same number of coordinates, $k$, and the maximum in each coordinate is also fixed at $n$. edit: the biggest difference, however, is that I think IV computes all of the vectors with the given parameters, whilst I want algebraic answers for general parameters.

( 2014-06-11 09:37:03 +0200 )edit

But I'm wondering whether they might have that built in as well...

( 2014-06-12 13:13:12 +0200 )edit