LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #1   Report Post  
Posted to microsoft.public.excel.programming
external usenet poster
 
Posts: 4
Default Generate specific matrix

Could someone help please
I m mathematician and would solve a problem I have, generating specific
matrix for each integer n
Could someone help me design a VBA prog that, for an integer n,
generate a matrix M = [A(l,c)] with following specs:
- M must be an n columns
- A(l,c) must be smaller or equal to c for every c smaller or equal to
n
- for every l integer and c integer smaller or equal to n, the integer
[ A(l,c) minus Max{1; 2; 3; ... A(l,c-1) ] is smaller or equal to 1
- no row is repeated
Many thanks for any idea to solve the problem
jiyed M




AAanother description:
- for an integer n, the matrix will be n-column
- no row is repeated
- for an integer c smaller or equal to n, the column c is populated by every
integer smaller or equal to c
- order of rows isn't important
Many thanks for any idea to solve the problem
jiyed M



examples

For n = 2, matrix is:
1 1
1 2


For n = 3, matrix is:
1 1 1
1 1 2
1 2 1
1 2 2
1 2 3


For n = 4, matrix is:
1 1 1 1
1 1 1 2
1 1 2 1
1 1 2 2
1 1 2 3
1 2 1 1
1 2 1 2
1 2 1 3
1 2 2 1
1 2 2 2
1 2 2 3
1 2 3 1
1 2 3 2
1 2 3 3
1 2 3 4


For n = 5, matrix is :
1 1 1 1 1
1 1 1 1 2
1 1 1 2 1
1 1 1 2 2
1 1 1 2 3
1 1 2 1 1
1 1 2 1 2
1 1 2 1 3
1 1 2 2 1
1 1 2 2 2
1 1 2 2 3
1 1 2 3 1
1 1 2 3 2
1 1 2 3 3
1 1 2 3 4
1 2 1 1 1
1 2 1 1 2
1 2 1 1 3
1 2 1 2 1
1 2 1 2 2
1 2 1 2 3
1 2 1 3 1
1 2 1 3 2
1 2 1 3 3
1 2 1 3 4
1 2 2 1 1
1 2 2 1 2
1 2 2 1 3
1 2 2 2 1
1 2 2 2 2
1 2 2 2 3
1 2 2 3 1
1 2 2 3 2
1 2 2 3 3
1 2 2 3 4
1 2 3 1 1
1 2 3 1 2
1 2 3 1 3
1 2 3 1 4
1 2 3 2 1
1 2 3 2 2
1 2 3 2 3
1 2 3 2 4
1 2 3 3 1
1 2 3 3 2
1 2 3 3 3
1 2 3 3 4
1 2 3 4 1
1 2 3 4 2
1 2 3 4 3
1 2 3 4 4
1 2 3 4 5

Many thanks in advance to help

--
mathematitien
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Randomly Generate Specific Data Bill Excel Worksheet Functions 2 November 14th 08 02:38 PM
How can I transpose nXm matrix to mXn Matrix MIHir Excel Worksheet Functions 2 August 9th 08 11:44 AM
Link from a specific Cell in Excel to a specific para. in Word CathyK Excel Worksheet Functions 0 August 10th 06 04:40 PM
generate a random number and use if function to generate new data Dogdoc1142 Excel Worksheet Functions 4 April 26th 06 03:44 AM
Matrix Attempt at solving a Matrix Problem? Excel Discussion (Misc queries) 2 August 15th 05 12:39 AM


All times are GMT +1. The time now is 12:17 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"