SMath Studio Forum
»
SMath Studio
»
Questions
»
Matrix size defined by variables
Rank: Newbie
Groups: Registered
Joined: 21/03/2018(UTC) Posts: 4 Location: Rosmalen
|
Does anyone know if it is possible to define a variable which will determine the size of a matrix. From where on the created matrix is again an input and not an output. For exaple: n:=1 (number of rows) m:=3 (number of koloms) creates a matrix of 1 kolom and 3 rows as below y:= [* * *] where the '*' are emty and can be spicified by the user. Beste regards, Rens Servais Edited by user 23 March 2018 17:32:00(UTC)
| Reason: Not specified
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 23/03/2016(UTC) Posts: 277 Was thanked: 91 time(s) in 57 post(s)
|
Check out this example. Matrix.sm (8kb) downloaded 39 time(s). |
|
|
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 981 time(s) in 809 post(s)
|
Originally Posted by: Rens Servais Does anyone know if it is possible to define a variable which will determine the size of a matrix. Both ways: empty and '0'
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 14/10/2015(UTC) Posts: 308
Was thanked: 77 time(s) in 58 post(s)
|
Other solution Best Regards Carlos
|
|
|
|
Rank: Newbie
Groups: Registered
Joined: 21/03/2018(UTC) Posts: 4 Location: Rosmalen
|
Originally Posted by: Jean Giraud Originally Posted by: Rens Servais Does anyone know if it is possible to define a variable which will determine the size of a matrix. Both ways: empty and '0' Thanks Jean Giraud, Your solution suits the best for me, but I can not reproduce it. See below. What do I do wrong? Beste regards, Rens Matrix.sm (32kb) downloaded 17 time(s).
|
|
|
|
Rank: Advanced Member Groups: Registered, Advanced Member Joined: 13/01/2012(UTC) Posts: 2,653 Location: Italy Was thanked: 1340 time(s) in 879 post(s)
|
|
If you like my plugins consider to support SMath Studio buying a plan; to offer me a coffee: paypal.me/dcprojects |
2 users thanked Davide Carpi for this useful post.
|
on 24/03/2018(UTC), on 24/03/2018(UTC)
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 981 time(s) in 809 post(s)
|
Originally Posted by: Rens Servais Your solution suits the best for me, but I can not reproduce it That will work for you. At this point, you can address any element. The empty matrix has almost no use.
|
|
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 981 time(s) in 809 post(s)
|
|
|
|
|
SMath Studio Forum
»
SMath Studio
»
Questions
»
Matrix size defined by variables
Forum Jump
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.