Skip to main content

Timeline for Find position without iterating

Current License: CC BY-SA 4.0

11 events
when toggle format what by license comment
Jan 7, 2019 at 13:36 comment added MikeY OK, I'll declare success. Again, thanks for the interesting problem, it gave me insight on my own.
Jan 7, 2019 at 8:20 comment added Hubble07 Note that for the case when Nm = Mm although it returns the correct value , it throws in some error. But its OK since for Nm = Mm @ciao function directly works fine.
Jan 7, 2019 at 2:30 history bounty ended Hubble07
Jan 7, 2019 at 2:30 vote accept Hubble07
Jan 7, 2019 at 1:09 history edited MikeY CC BY-SA 4.0
deleted 3 characters in body
Jan 6, 2019 at 18:47 history edited MikeY CC BY-SA 4.0
Updated to match the updated question
Jan 3, 2019 at 13:58 history edited MikeY CC BY-SA 4.0
added 71 characters in body
Jan 3, 2019 at 13:39 history edited MikeY CC BY-SA 4.0
Some clarification of the sort order
Jan 3, 2019 at 12:03 comment added MikeY By using my ordering, I was able to count my way through to a closed form for ordering and indexing. It also offers a path to creating the solutions that doesn’t involve a Solve[ ]. I didn’t see an obvious counting scheme in your SortBy[ ] ordering, but the approach of decomposing the problem I figured could inspire you. This is similar to a problem I have, and working on yours helped me quite a bit, so, thanks for posing it!
Jan 3, 2019 at 6:53 comment added Hubble07 But is there a way to get the correct ordering otherwise how would I use this code. Maybe there is a mapping from your ordering to what I want which holds for any (N_m, M_m) value. Also see my edit in the question. Please check your speed with the naive approach. I would like a solution that firstly gives the actual position and secondly it should be considerably faster than the trivial method I have shown. Anyway I really appreciate the time and effort you have shown. Thank you very much. I will wait to see if someone can provide an answer that meets my criteria.
Jan 2, 2019 at 22:37 history answered MikeY CC BY-SA 4.0