Line intersections - An example of translation of a function from Matlab to Smath - Messages
#41 Posted: 2/19/2018 6:36:00 AM
Hello Everybody,
Thanks to all of you for these extremely interesting postings.
I am barely able to fully understand them in depth... I need a bit of time to study them thoroughly.
Programming is like making music, and this is a symphony!!
Once again, thanks for all these good suggestions.
Marco
Thanks to all of you for these extremely interesting postings.
I am barely able to fully understand them in depth... I need a bit of time to study them thoroughly.
Programming is like making music, and this is a symphony!!
Once again, thanks for all these good suggestions.
Marco
#42 Posted: 2/20/2018 1:08:59 AM
WroteStill on line intersections.
Bug corrected: only lines with same number of points were accepted.
Now lines with different # of points will work.
Also some improvements in efficiency so that runtime is now
approx. -25%.
Marco, your Line Intersection is a piece of gold for Engineering works.
1. Trifolium
2. Dragilev implicit solve
3. Focus [suggested as next exercise]
Zillions thanks ... Jean
Maths InterX.r1 (2) Trifolium Copy.sm (103 KiB) downloaded 78 time(s).
#43 Posted: 2/21/2018 5:34:53 PM
Wrote
WroteFor such uses it would be good if the augment and stack functions could expand scalar arguments (or more generally any arguments not matching the maximum number of rows or cols) to uniformly populated vectors of the required size).
This is what I've got after improving stack/augment (see SMath Studio 0.99.6626):
Note, that I had to make height of the result matrix about 40 times larger to see the same time! This means that this syntax of stack/augment is about 40 times faster then without it.
Thank you!
6 users liked this post
Radovan Omorjan 2/21/2018 6:38:00 PM, frapuano 2/21/2018 6:58:00 PM, sergio 2/21/2018 5:53:00 PM, Davide Carpi 2/22/2018 6:14:00 AM, MBe 2/22/2018 12:41:00 PM, NDTM Amarasekera 2/21/2018 11:06:00 PM
#44 Posted: 2/22/2018 12:55:14 PM
WroteThis is what I've got after improving stack/augment (see SMath Studio 0.99.6626):
Looks great, not reproducible 6179.
Could it conflict in other situations ?
-
New Posts
-
No New Posts