Thanks to visit codestin.com
Credit goes to github.com

Skip to content

fixed expanded_actions( ), added CSPlan with n-ary CSP definition, problems and tests, AC3b and AC4 with tests #1113

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 65 commits into from
Sep 16, 2019

Conversation

dmeoli
Copy link
Contributor

@dmeoli dmeoli commented Sep 12, 2019

  • fixed planning.py: expanded_actions( ) generates actions which doesn't satisfy the arguments' domain #1111
  • added the CSPlan [Section 10.4.3] with the definition of a CSP with n-ary constraints and some problems including the cryptarithmetic puzzle T W O + T W O = F O U R [Figure 6.2]
  • AC3b, an improved version of AC-3 with double-support check domain-heuristic which has the same complexity of AC-3, O(cd^3), but is faster on average cases
  • AC4 (page 210, footnote 1) which runs in O(cd^2) worst-case time but can be slower than AC-3 on average cases

dmeoli added 30 commits March 24, 2019 17:03
Changed queue to set in AC3 (as in the pseudocode of the original algorithm) to reduce the number of consistency-check due to the redundancy of the same arcs in queue. For example, on the harder1 configuration of the Sudoku CSP the number consistency-check has been reduced from 40464 to 12562!
AC3 algorithm has non-optimal worst case time-complexity O(cd^3 ), while AC4 algorithm runs in O(cd^2) worst case time
…he constant propagation algorithm in mac inference
… are already present in test_csp.py"

This reverts commit b3cd24c.
…oosing the constant propagation algorithm in mac inference"

This reverts commit 6986247.
This reverts commit 6641c2c.
@dmeoli dmeoli changed the title fixed expanded_actions( ), added CSPlan and tests with NaryCSP definition fixed expanded_actions( ), added CSPlan with n-ary CSP definition and tests Sep 12, 2019
Copy link
Collaborator

@antmarakis antmarakis left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall pretty good, but I want to double-check whether the @staticmethod markers can be removed or not. I would like to keep code as consistent as possible, and if the program runs without them, then they should be removed.

@dmeoli
Copy link
Contributor Author

dmeoli commented Sep 15, 2019 via email

@dmeoli dmeoli changed the title fixed expanded_actions( ), added CSPlan with n-ary CSP definition and tests fixed expanded_actions( ), added CSPlan with n-ary CSP definition, problems and tests, AC3b and AC4 with tests Sep 15, 2019
@antmarakis antmarakis merged commit 440142c into aimacode:master Sep 16, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

planning.py: expanded_actions( ) generates actions which doesn't satisfy the arguments' domain
2 participants