Multidimensional nested array
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Multidimensional nested array
Hi , I woul apreciate if someoane can help to convert de nested array in a matrix
Solved! Go to Solution.
- Labels:
-
Programming
Accepted Solutions
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thank you very much, I really appreciate the answer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Looking for a routine like my "cleanUp" ?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Thank you very much, I really appreciate the answer
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
How could the program be modified if the origin is 1?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
So no modifications needed.
Success!
Luc
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Luc is correct - my function should work OK with any value of ORIGIN.
At the top of the function I assign the value of ORIGIN to a variable O.
You must take care that throughout the function you are using O (the letter) and not 0 (zero).
There is not a single zero in this function - whatever looks like a zero is a capital letter O.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi, I would appreciate a help to convert the nested matrix of the figure into a matrix.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I should think that the very same program can also handle this nested matrix.
You did not provide the matrix, just a picture of it. Assuming you have it as a (nested) matrix, just supply it to the function.
Success!
Luc
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
OK, I see the problems:
1) The routine I provided did not work OK with matrices of just one row or just one column
2) Your matrix PP is even nested one step further than the example you provided in your initial question and so my routine would not deal with it correctly.
Any of the following three functions should fix this and should work with any nesting level and of course any value of ORIGIN - take your choice:
P.S.: For future questions please keep in mind to
1) say which version of Mathcad you are using (I just see from your screenshot that its real Mathcad and not Prime)
2) always attach your Mathcad worksheet whenever possible and not just pictures!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Dear:
I appreciate your answer, I have tried it and it works perfectly. I have taken the recommendations into account.
Thank you very much.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Hi, I would like to know how I can generate a vector [cc] as shown in the mathcad sheet. Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
You may even try in on multiple nested matrices
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Modification:
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
I would also appreciate knowing how to generate the vector cc1. Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
@rcallisaya wrote:
I would also appreciate knowing how to generate the vector cc1. Thank you
You didn't read my answer, did you?
You just type cc1:=unravel1(gdt) (or use unravel2 if you like)
BTW - you don't need to use the function "rowS", you may use the built-in function "rows" instead.
The vector cc1 you ask for is the very same as the vector cc you asked before.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Notify Moderator
Ok. Thanks.
