Beefy Boxes and Bandwidth Generously Provided by pair Networks
more useful options
 
PerlMonks  

Re^3: Highest total sum path problem

by QM (Parson)
on Mar 05, 2020 at 11:25 UTC ( #11113840=note: print w/replies, xml ) Need Help??


in reply to Re^2: Highest total sum path problem
in thread Highest total sum path problem

Can you clarify the problem statement?

For instance, is it legal to try to do a tour of the matrix, to pick up as many high value cells as possible? If the priority is "max sum", followed by "min terms", then a "rook's tour" of the positive valued cells is in order.

Another idea, can you revisit a cell? What's to keep you from circling through 4 positive value cells forever?

Can you go "offline", by taking a longer tour than necessary?

-QM
--
Quantum Mechanics: The dreams stuff is made of

Replies are listed 'Best First'.
Re^4: Highest total sum path problem
by baxy77bax (Deacon) on Mar 05, 2020 at 17:03 UTC
    a) It is legal to do a tour of the matrix and pick up as many high value cells as possible. :)

    b) this is not legal... each cell can only be visited once (but if this was associated to some fintech problem where total sum is your account balance, I guess this would be a good way to boost it up :D )

    c)Yes you can go offline if the number of moves is higher that the total sum of the path toward the final value (cell), but this only holds if a path already exists. If it is the initial search then there is no reference and the condition does not hold (at least one path (solution) needs to exist )

    thnx I did not catch those conditions but now that you mentioned it i see how they are crucial for the problem

    by helping you I helped myself. Thank you !!!

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11113840]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others perusing the Monastery: (5)
As of 2021-09-17 09:47 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?