SMath Studio Forum
»
SMath Studio
»
Bugs & Problems
»
bug in matrix function involving a double loop
Rank: Advanced Member Groups: Registered
Joined: 13/09/2011(UTC) Posts: 66 Location: Kolkata
Was thanked: 9 time(s) in 9 post(s)
|
Hello, there is a simple turnaround so it's not a big deal, but still... This looks like a bug... Or is there something I didn't understand? I like to see the numbers in my engineering calculations, that why I use matrices. Thanks everyone for your help/advice, Thank you Andrey for this incredible software. Regards Laurent bug.sm (12kb) downloaded 9 time(s).
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 23/12/2011(UTC) Posts: 321 Location: italy Was thanked: 110 time(s) in 94 post(s)
|
It's not really a bug but a smath behavior. If you add an "eval" that forces the numerical evaluation of the nested producer, it works bug(s).sm (7kb) downloaded 13 time(s).sergio
|
1 user thanked PompelmoTell for this useful post.
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 15/04/2012(UTC) Posts: 2,023 Was thanked: 1153 time(s) in 739 post(s)
|
I'd still call it a bug. Is there any good reason why definition and display in separate cells behave differently from definition and display in the same cell? There is no problem with def and display in different cells with the original definition (without eval). You also can use M:eval(sumofproduct(Ma))= One would expect that the combination a:b=c would store b in a and then display a just as it would be displayed with a= in a subsequent cell. Obviously this is not the case, either because - there is a good reason from usage point of view (which I don't know) or - there is a good reason from development point of view (e.g. too complicated to do it this way) or - it is just a bug. The error message "j not defined" is definitely a bug, why would one expect loop variables to require an additional definition. In case the behaviour is too hard to fix, I would even recommend to remove the feature of display and def in the same cell. I know I was among those who asked for it many years ago but not at the cost of having to weave eval() into the sheet wherever it might help. Edited by user 30 March 2022 00:45:59(UTC)
| Reason: Not specified |
|
2 users thanked mkraska for this useful post.
|
on 29/03/2022(UTC), on 30/03/2022(UTC)
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 983 time(s) in 811 post(s)
|
Augmented version ... no red SS 6179 If you don't see or have red the 3 blocks, please let me know for a snippet image. Cheers ... Jean. bug 6179.sm (40kb) downloaded 5 time(s).
|
|
|
|
Rank: Advanced Member Groups: Registered
Joined: 23/07/2013(UTC) Posts: 1,159 Was thanked: 526 time(s) in 352 post(s)
|
Originally Posted by: mkraska I'd still call it a bug. Yes, me too. sum() and product() creates havoc sometimes. The bug can be iron out with line() also, but why? Why we need line() or eval() or symbolic/numeric to resolve these kind of issues? sum() and product() used functions can't solve() or roots() too.
|
|
|
|
Rank: Guest
Groups: Registered
Joined: 04/07/2015(UTC) Posts: 6,866 Was thanked: 983 time(s) in 811 post(s)
|
Originally Posted by: Jean Giraud no red SS 6179
|
|
|
|
SMath Studio Forum
»
SMath Studio
»
Bugs & Problems
»
bug in matrix function involving a double loop
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.