x


Tree from Matrix

Hi, I want to sort a matrix in a tree, where 1. the first element represent the parent and all the rest are inside it 2. except the first one, the rest may not follow any order of inclusion relationship here is the matrix, 1, 2, 3, 4, 5, 6, 7, 8 2, 3, 4, 5 4, 3, 5 3, 5 5 6, 7 7 8 9, 10 10 The problems are 1. is how would I know which one is the imedaite parent of i.e 3 or 7 or 8 2. 9 is another root node (which do not have any parent like 1)

more ▼

asked Dec 13, 2011 at 04:08 PM

farazjanan gravatar image

farazjanan
1 1 2 2

(comments are locked)
10|3000 characters needed characters left

0 answers: sort voted first
Be the first one to answer this question
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x367
x27

asked: Dec 13, 2011 at 04:08 PM

Seen: 518 times

Last Updated: Dec 13, 2011 at 04:08 PM