Boost logo

Boost Users :

From: Pascal Bauer (pascal.bauer_at_[hidden])
Date: 2005-08-22 07:16:41


Hello,

I have the following problem:

Given

typedef mpl::vector_c<int, 3, 0, 3, 6, 9> MyVector;

Now, I wish to create a mpl::vector with 3 entries that look like

mpl::vector<
mpl::vector_c<int, 1, 0, 3, 6, 9>,
mpl::vector_c<int, 1, 1, 4, 7, 10>,
mpl::vector_c<int, 1, 2, 5, 8, 11> >

In words

The first number in MyVector gives me the number of resulting vector_c types.
the resulting types should contain a 1 instead of that number. The other
numbers should be replace gradualy: The first vector_c should contain the
same numbers as the original type. In the second vector_c, all the numbers
should be incremented by one, and so forth.

I have to admit, that this task overstrains me, so it would be very kind, if
someone could help me to figure this out.

Cheers

Pascal Bauer

-- 
************************************
* Pascal Bauer                     *
*                                  *
* Theoretical Astrophysics Group   *
* Mail: pascal.bauer_at_[hidden] *
************************************

Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net