SlideShare uma empresa Scribd logo
1 de 35
INTELLIGENT SUDOKU SOLVER
Under the Guidance of
Dr. SUNIL PATEKAR
Group Members:
1. Amrish Jhaveri
2. Rohit Iyer
3. Krutika Parab
UNIVERSITY OF MUMBAI
2012-2013
CONTENTS
I. INTRODUCTION
II. AIMS & OBJECTIVES
III. PROBLEM STATEMENT
IV. SCOPE
V. PROPOSED SYSTEM
VI. METHODOLOGY – Expert System
VII. BACKTRACKING ALGORITHM
VIII. PATTERNS
IX. DESIGN – Flow Chart
2
INTELLIGENT SUDOKU SOLVER
X. FEATURES
XI. CODE SNIPPETS
I. INTRODUCTION
 Rule:
Fill a given grid(9x9) with the numbers 1 to 9, so that every column,
row, and 3x3 box the numbers 1 to 9, keeping in mind that the same
number doesn’t repeat in that particular row, column or the 3x3 box.
3
INTELLIGENT SUDOKU SOLVER
II. AIMS & OBJECTIVES
 To successfully implement a novel approach to solve
computationally intensive problems like Sudoku.
 To solve the classical Sudoku puzzle in a much more efficient way
than a conventional Brute Force and Backtracking approach.
4
INTELLIGENT SUDOKU SOLVER
III. PROBLEM STATEMENT
 Our job is to place a number into every empty box so that each
row across, each column down, and each small 9-box square
within the large square (there are 9 of these) will contain each
number from 1 through 9. Remember that no number may appear
more than once in any row across, any column down, or within
any small 9-box square. The numbers will be filled with the
help of pattern matching.
5
INTELLIGENT SUDOKU SOLVER
IV. SCOPE
 Our project aims at solving Sudoku using pattern matching.
 Assumptions:
• Fixed Grid Size: 9 x 9
• Fixed Symbols: 1-9
• Limitations on the number of patterns implemented.
6
INTELLIGENT SUDOKU SOLVER
V. PROPOSED SYSTEM
 Our project uses five main modules:
1. Reading the input from file.
2. Search for patterns.
3. Provide solution.
4. Solve by Backtracking.
5. Compare the run-time.
7
INTELLIGENT SUDOKU SOLVER
VI. EXPERT SYSTEM
 In Artificial Intelligence, an Expert System is a computer
system that emulates the decision-making ability of a human
expert.
 It consists of a rule-base (permanent data), an inference engine
(process), and a workspace or working memory (temporary
data). Not part of the basic reasoning process, but essential to
applications, is the user interface.
8
INTELLIGENT SUDOKU SOLVER
VI. EXPERT SYSTEM
9
INTELLIGENT SUDOKU SOLVER
VI. EXPERT SYSTEM
 In our approach the components of expert system are as follows:
• Client interface is a command line interface or GUI.
• Knowledge base are set of data structures stored which contain prior
information needed to proceed.
• Rule translator is a function which translates the rule from human
understandable form to machine understandable form. For e.g. A function called
HiddenSingles() may translate the rule in such a way that the Rule Engine (in
our case – our main program)understands.
• Knowledge base editor would be a simple text editor which can change/add
the built-in rules in the code.
• Rule Engine is another function which checks every pattern if it matches a
rule or not. 10
INTELLIGENT SUDOKU SOLVER
VII. BACKTRACKING ALGORITHM
 We basically check that the same number is not present in
current row, current column and current 3X3 sub grid. After
checking for safety, we assign the number, and recursively check
whether this assignment leads to a solution or not. If the
assignment doesn’t lead to a solution, then we try next number
for current empty cell. And if none of number (1 to 9) lead to
solution, we return false.
11
INTELLIGENT SUDOKU SOLVER
VIII. PATTERNS
 NAKED SINGLE
 Any cells which have only one candidate can safely be
assigned that value.
 It is very important whenever a value is assigned to a cell,
that this value is also excluded as a candidate from all other
blank cells sharing the same row, column and box
12
INTELLIGENT SUDOKU SOLVER
 NAKED SINGLE
13
INTELLIGENT SUDOKU SOLVER
VIII. PATTERNS
 NAKED PAIR
 A Naked Pair (also known as a Conjugate Pair) is a set of two
candidate numbers sited in two cells that belong to at least
one unit in common. That is they reside in the same row, box
or column.
14
INTELLIGENT SUDOKU SOLVER
VIII. PATTERNS
IX. PATTERNS
 NAKED PAIR
15
INTELLIGENT SUDOKU SOLVER
 HIDDEN SINGLE
 Very frequently, there is only one candidate for a given
row, column or box, but it is hidden among other candidates.
 In the example on the right, the
candidate 6 is only found in the
middle right cell of the 3x3 box.
Since every box must have a
6, this cell must be that 6.
16
INTELLIGENT SUDOKU SOLVER
VIII. PATTERNS
 Locked Candidates -I
 Sometimes a candidate within a box is
restricted to one row or column. Since one of
these cells must contain that specific
candidate, the candidate can safely be
excluded from the remaining cells in that row
or column outside of the box.
VIII. PATTERNS
INTELLIGENT SUDOKU SOLVER
 Locked Candidates – I Example
In the example above, the right box only has candidate 2's in its bottom row.
Since, one of those cells must be a 2, no cells in that row outside that box
can be a 2. Therefore 2 can be excluded as a candidate from the highlighted
cells.
VIII. PATTERNS
INTELLIGENT SUDOKU SOLVER
 Locked Candidates – II
 Sometimes a candidate within a row or
column is restricted to one box. Since one of
these cells must contain that specific
candidate, the candidate can safely be
excluded from the remaining cells in the box.
VIII. PATTERNS
INTELLIGENT SUDOKU SOLVER
 Locked Candidates – II Example
In the example on the right, the left column
has candidate 9's only in the middle box.
Therefore, since one of these cells must be a
9 (otherwise the column would be without a
9), 9's can safely be excluded from all cells in
this middle box except those in the left
column.
VIII. PATTERNS
INTELLIGENT SUDOKU SOLVER
IX. DESIGN (FLOW CHART)
21
INTELLIGENT SUDOKU SOLVER
Yes
No
Yes
No
Reading Sudoku
from a file
Search patterns
Take necessary
action
Solved?
Print Solution
Stop
Start
Make a smart
guess Found
X. FEATURES
 A Java based Sudoku Solver
 Benchmarked at solving 49151 random puzzles within 16159
milliseconds.
 Used optimized pattern detection strategies like Naked Singles,
Hidden
 Singles and Locked Candidates to aid solving.
 Reviewed the performance of our solver with existing Sudoku
Solvers in the world.
 Comprehensive statistical and graphical results to record the solver's
performance using JFreeChart API.
INTELLIGENT SUDOKU SOLVER
We conducted a test on
some of the world’s popular
and fastest Sudoku solvers.
The test consisted of
solving 1000 very hard
puzzles.
We fed the same set of
1000 puzzles to all solvers
and result is here….
INTELLIGENT SUDOKU SOLVER
OUR OPPONENT….
… a puzzle took 15.5 billion nanoseconds!!!
INTELLIGENT SUDOKU SOLVER
OUR INTELLIGENT SOLVER….
… a puzzle took 25 million nanoseconds!!!
INTELLIGENT SUDOKU SOLVER
NO COMPARISON!!!
… can’t compare millions with billions!!!
INTELLIGENT SUDOKU SOLVER
NO COMPARISON!!!
… can’t compare millions with billions!!!
INTELLIGENT SUDOKU SOLVER
XI. CODE SNIPPETS
INTELLIGENT SUDOKU SOLVER
28
INTELLIGENT SUDOKU SOLVER
XI. CODE SNIPPETS
INTELLIGENT SUDOKU SOLVER
30
XI. CODE SNIPPETS
INTELLIGENT SUDOKU SOLVER
32
Our paper titled -
has been reviewed
and accepted by International
Journal of Scientific Research
and Publications and will be
published in Volume 3, Issue
5, May 2013.
INTELLIGENT SUDOKU SOLVER
THANK YOU
 We would like to thank our project guide Dr. Sunil Patekar &
Prof Mahesh Bhave for helping us identify the flaws and correcting
them. We would also like to thank Assistant Professors Rugved
Deolekar and Aman Mahadeshwar for their inputs.
35
INTELLIGENT SUDOKU SOLVER

Mais conteúdo relacionado

Mais procurados (20)

Sudoku solver
Sudoku solverSudoku solver
Sudoku solver
 
N queen problem
N queen problemN queen problem
N queen problem
 
The n Queen Problem
The n Queen ProblemThe n Queen Problem
The n Queen Problem
 
Sudoku
SudokuSudoku
Sudoku
 
BackTracking Algorithm: Technique and Examples
BackTracking Algorithm: Technique and ExamplesBackTracking Algorithm: Technique and Examples
BackTracking Algorithm: Technique and Examples
 
Sudoku
SudokuSudoku
Sudoku
 
sum of subset problem using Backtracking
sum of subset problem using Backtrackingsum of subset problem using Backtracking
sum of subset problem using Backtracking
 
Knapsack problem
Knapsack problemKnapsack problem
Knapsack problem
 
N queens using backtracking
N queens using backtrackingN queens using backtracking
N queens using backtracking
 
factoring
factoringfactoring
factoring
 
Backtracking Algorithm.ppt
Backtracking Algorithm.pptBacktracking Algorithm.ppt
Backtracking Algorithm.ppt
 
Backtracking
BacktrackingBacktracking
Backtracking
 
Job sequencing with Deadlines
Job sequencing with DeadlinesJob sequencing with Deadlines
Job sequencing with Deadlines
 
Graph coloring problem
Graph coloring problemGraph coloring problem
Graph coloring problem
 
Dijkstra's algorithm presentation
Dijkstra's algorithm presentationDijkstra's algorithm presentation
Dijkstra's algorithm presentation
 
Branch and bound
Branch and boundBranch and bound
Branch and bound
 
Activity Selection Problem
Activity Selection ProblemActivity Selection Problem
Activity Selection Problem
 
Cryptography and Information Security
Cryptography and Information SecurityCryptography and Information Security
Cryptography and Information Security
 
Dinive conquer algorithm
Dinive conquer algorithmDinive conquer algorithm
Dinive conquer algorithm
 
Fractional Knapsack Problem
Fractional Knapsack ProblemFractional Knapsack Problem
Fractional Knapsack Problem
 

Destaque

Sudoku powerpoint
Sudoku powerpointSudoku powerpoint
Sudoku powerpointunion40
 
Reservation Presentation
Reservation PresentationReservation Presentation
Reservation PresentationAmrish Jhaveri
 
My Project Report Documentation with Abstract & Snapshots
My Project Report Documentation with Abstract & SnapshotsMy Project Report Documentation with Abstract & Snapshots
My Project Report Documentation with Abstract & SnapshotsUsman Sait
 
L1 Sudoku
L1 SudokuL1 Sudoku
L1 Sudokubnmoran
 
Cours Génie Logiciel 2016
Cours Génie Logiciel 2016Cours Génie Logiciel 2016
Cours Génie Logiciel 2016Erradi Mohamed
 
My hobby my interest
My hobby my interestMy hobby my interest
My hobby my interestLAURABABIIEE
 
How to Make Awesome SlideShares: Tips & Tricks
How to Make Awesome SlideShares: Tips & TricksHow to Make Awesome SlideShares: Tips & Tricks
How to Make Awesome SlideShares: Tips & TricksSlideShare
 
Getting Started With SlideShare
Getting Started With SlideShareGetting Started With SlideShare
Getting Started With SlideShareSlideShare
 

Destaque (18)

Sudoku ppt
Sudoku pptSudoku ppt
Sudoku ppt
 
Sudoku powerpoint
Sudoku powerpointSudoku powerpoint
Sudoku powerpoint
 
Sudoku
SudokuSudoku
Sudoku
 
Sudoku
SudokuSudoku
Sudoku
 
Reservation Presentation
Reservation PresentationReservation Presentation
Reservation Presentation
 
My Project Report Documentation with Abstract & Snapshots
My Project Report Documentation with Abstract & SnapshotsMy Project Report Documentation with Abstract & Snapshots
My Project Report Documentation with Abstract & Snapshots
 
L1 Sudoku
L1 SudokuL1 Sudoku
L1 Sudoku
 
Reservation in India
Reservation in IndiaReservation in India
Reservation in India
 
Cours Génie Logiciel 2016
Cours Génie Logiciel 2016Cours Génie Logiciel 2016
Cours Génie Logiciel 2016
 
Reservation
ReservationReservation
Reservation
 
My presentation about hobby
My presentation about hobbyMy presentation about hobby
My presentation about hobby
 
My hobbies
My hobbiesMy hobbies
My hobbies
 
Types of reservation
Types of reservationTypes of reservation
Types of reservation
 
My hobby my interest
My hobby my interestMy hobby my interest
My hobby my interest
 
My hobby
My hobbyMy hobby
My hobby
 
Hobbies and interests
Hobbies and interestsHobbies and interests
Hobbies and interests
 
How to Make Awesome SlideShares: Tips & Tricks
How to Make Awesome SlideShares: Tips & TricksHow to Make Awesome SlideShares: Tips & Tricks
How to Make Awesome SlideShares: Tips & Tricks
 
Getting Started With SlideShare
Getting Started With SlideShareGetting Started With SlideShare
Getting Started With SlideShare
 

Semelhante a Intelligent Sudoku Solver

Stackpirt20170222
Stackpirt20170222Stackpirt20170222
Stackpirt20170222Sharon Liu
 
Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...
Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...
Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...VIT-AP University
 
MachinaFiesta: A Vision into Machine Learning 🚀
MachinaFiesta: A Vision into Machine Learning 🚀MachinaFiesta: A Vision into Machine Learning 🚀
MachinaFiesta: A Vision into Machine Learning 🚀GDSCNiT
 
Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...
Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...
Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...IOSR Journals
 
Ai demystified (dbe, south campus)
Ai  demystified (dbe, south campus)Ai  demystified (dbe, south campus)
Ai demystified (dbe, south campus)SaurabhKhanna31
 
Neural Networks by Priyanka Kasture
Neural Networks by Priyanka KastureNeural Networks by Priyanka Kasture
Neural Networks by Priyanka KasturePriyanka Kasture
 
SURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNING
SURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNINGSURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNING
SURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNINGIRJET Journal
 
Introduction to Neural Networks in Tensorflow
Introduction to Neural Networks in TensorflowIntroduction to Neural Networks in Tensorflow
Introduction to Neural Networks in TensorflowNicholas McClure
 
Reds interpretability report
Reds interpretability reportReds interpretability report
Reds interpretability reportRaouf KESKES
 
2011 0480.neural-networks
2011 0480.neural-networks2011 0480.neural-networks
2011 0480.neural-networksParneet Kaur
 
FP vs OOP : Design Methodology by Harshad Nawathe
FP vs OOP : Design Methodology by Harshad NawatheFP vs OOP : Design Methodology by Harshad Nawathe
FP vs OOP : Design Methodology by Harshad NawatheChandulal Kavar
 
An approach to solve the N-Queens Problem using Artificial Intelligence algor...
An approach to solve the N-Queens Problem using Artificial Intelligence algor...An approach to solve the N-Queens Problem using Artificial Intelligence algor...
An approach to solve the N-Queens Problem using Artificial Intelligence algor...IRJET Journal
 
Hpai class 16 - learning - 041320
Hpai   class 16 - learning - 041320Hpai   class 16 - learning - 041320
Hpai class 16 - learning - 041320melendez321
 

Semelhante a Intelligent Sudoku Solver (20)

NPTEL complete.pptx.pptx
NPTEL complete.pptx.pptxNPTEL complete.pptx.pptx
NPTEL complete.pptx.pptx
 
NPTEL_SEM_3.pdf
NPTEL_SEM_3.pdfNPTEL_SEM_3.pdf
NPTEL_SEM_3.pdf
 
21AI401 AI Unit 1.pdf
21AI401 AI Unit 1.pdf21AI401 AI Unit 1.pdf
21AI401 AI Unit 1.pdf
 
P1
P1P1
P1
 
Stackpirt20170222
Stackpirt20170222Stackpirt20170222
Stackpirt20170222
 
Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...
Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...
Low Power 32×32 bit Multiplier Architecture based on Vedic Mathematics Using ...
 
MachinaFiesta: A Vision into Machine Learning 🚀
MachinaFiesta: A Vision into Machine Learning 🚀MachinaFiesta: A Vision into Machine Learning 🚀
MachinaFiesta: A Vision into Machine Learning 🚀
 
Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...
Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...
Universal Artificial Intelligence for Intelligent Agents: An Approach to Supe...
 
Core java questions
Core java questionsCore java questions
Core java questions
 
Core java questions
Core java questionsCore java questions
Core java questions
 
Ai demystified (dbe, south campus)
Ai  demystified (dbe, south campus)Ai  demystified (dbe, south campus)
Ai demystified (dbe, south campus)
 
Neural Networks by Priyanka Kasture
Neural Networks by Priyanka KastureNeural Networks by Priyanka Kasture
Neural Networks by Priyanka Kasture
 
Tutorial olap4j
Tutorial olap4jTutorial olap4j
Tutorial olap4j
 
SURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNING
SURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNINGSURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNING
SURVEY ON BRAIN – MACHINE INTERRELATIVE LEARNING
 
Introduction to Neural Networks in Tensorflow
Introduction to Neural Networks in TensorflowIntroduction to Neural Networks in Tensorflow
Introduction to Neural Networks in Tensorflow
 
Reds interpretability report
Reds interpretability reportReds interpretability report
Reds interpretability report
 
2011 0480.neural-networks
2011 0480.neural-networks2011 0480.neural-networks
2011 0480.neural-networks
 
FP vs OOP : Design Methodology by Harshad Nawathe
FP vs OOP : Design Methodology by Harshad NawatheFP vs OOP : Design Methodology by Harshad Nawathe
FP vs OOP : Design Methodology by Harshad Nawathe
 
An approach to solve the N-Queens Problem using Artificial Intelligence algor...
An approach to solve the N-Queens Problem using Artificial Intelligence algor...An approach to solve the N-Queens Problem using Artificial Intelligence algor...
An approach to solve the N-Queens Problem using Artificial Intelligence algor...
 
Hpai class 16 - learning - 041320
Hpai   class 16 - learning - 041320Hpai   class 16 - learning - 041320
Hpai class 16 - learning - 041320
 

Último

WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...Zilliz
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...apidays
 
Introduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDMIntroduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDMKumar Satyam
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MIND CTI
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityWSO2
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FMESafe Software
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesrafiqahmad00786416
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Victor Rentea
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Orbitshub
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfOrbitshub
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...apidays
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKJago de Vreede
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerThousandEyes
 

Último (20)

Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 
WSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering DevelopersWSO2's API Vision: Unifying Control, Empowering Developers
WSO2's API Vision: Unifying Control, Empowering Developers
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Introduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDMIntroduction to use of FHIR Documents in ABDM
Introduction to use of FHIR Documents in ABDM
 
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data DiscoveryTrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
TrustArc Webinar - Unlock the Power of AI-Driven Data Discovery
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Platformless Horizons for Digital Adaptability
Platformless Horizons for Digital AdaptabilityPlatformless Horizons for Digital Adaptability
Platformless Horizons for Digital Adaptability
 
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers:  A Deep Dive into Serverless Spatial Data and FMECloud Frontiers:  A Deep Dive into Serverless Spatial Data and FME
Cloud Frontiers: A Deep Dive into Serverless Spatial Data and FME
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
Modular Monolith - a Practical Alternative to Microservices @ Devoxx UK 2024
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUKSpring Boot vs Quarkus the ultimate battle - DevoxxUK
Spring Boot vs Quarkus the ultimate battle - DevoxxUK
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 

Intelligent Sudoku Solver

  • 1. INTELLIGENT SUDOKU SOLVER Under the Guidance of Dr. SUNIL PATEKAR Group Members: 1. Amrish Jhaveri 2. Rohit Iyer 3. Krutika Parab UNIVERSITY OF MUMBAI 2012-2013
  • 2. CONTENTS I. INTRODUCTION II. AIMS & OBJECTIVES III. PROBLEM STATEMENT IV. SCOPE V. PROPOSED SYSTEM VI. METHODOLOGY – Expert System VII. BACKTRACKING ALGORITHM VIII. PATTERNS IX. DESIGN – Flow Chart 2 INTELLIGENT SUDOKU SOLVER X. FEATURES XI. CODE SNIPPETS
  • 3. I. INTRODUCTION  Rule: Fill a given grid(9x9) with the numbers 1 to 9, so that every column, row, and 3x3 box the numbers 1 to 9, keeping in mind that the same number doesn’t repeat in that particular row, column or the 3x3 box. 3 INTELLIGENT SUDOKU SOLVER
  • 4. II. AIMS & OBJECTIVES  To successfully implement a novel approach to solve computationally intensive problems like Sudoku.  To solve the classical Sudoku puzzle in a much more efficient way than a conventional Brute Force and Backtracking approach. 4 INTELLIGENT SUDOKU SOLVER
  • 5. III. PROBLEM STATEMENT  Our job is to place a number into every empty box so that each row across, each column down, and each small 9-box square within the large square (there are 9 of these) will contain each number from 1 through 9. Remember that no number may appear more than once in any row across, any column down, or within any small 9-box square. The numbers will be filled with the help of pattern matching. 5 INTELLIGENT SUDOKU SOLVER
  • 6. IV. SCOPE  Our project aims at solving Sudoku using pattern matching.  Assumptions: • Fixed Grid Size: 9 x 9 • Fixed Symbols: 1-9 • Limitations on the number of patterns implemented. 6 INTELLIGENT SUDOKU SOLVER
  • 7. V. PROPOSED SYSTEM  Our project uses five main modules: 1. Reading the input from file. 2. Search for patterns. 3. Provide solution. 4. Solve by Backtracking. 5. Compare the run-time. 7 INTELLIGENT SUDOKU SOLVER
  • 8. VI. EXPERT SYSTEM  In Artificial Intelligence, an Expert System is a computer system that emulates the decision-making ability of a human expert.  It consists of a rule-base (permanent data), an inference engine (process), and a workspace or working memory (temporary data). Not part of the basic reasoning process, but essential to applications, is the user interface. 8 INTELLIGENT SUDOKU SOLVER
  • 10. VI. EXPERT SYSTEM  In our approach the components of expert system are as follows: • Client interface is a command line interface or GUI. • Knowledge base are set of data structures stored which contain prior information needed to proceed. • Rule translator is a function which translates the rule from human understandable form to machine understandable form. For e.g. A function called HiddenSingles() may translate the rule in such a way that the Rule Engine (in our case – our main program)understands. • Knowledge base editor would be a simple text editor which can change/add the built-in rules in the code. • Rule Engine is another function which checks every pattern if it matches a rule or not. 10 INTELLIGENT SUDOKU SOLVER
  • 11. VII. BACKTRACKING ALGORITHM  We basically check that the same number is not present in current row, current column and current 3X3 sub grid. After checking for safety, we assign the number, and recursively check whether this assignment leads to a solution or not. If the assignment doesn’t lead to a solution, then we try next number for current empty cell. And if none of number (1 to 9) lead to solution, we return false. 11 INTELLIGENT SUDOKU SOLVER
  • 12. VIII. PATTERNS  NAKED SINGLE  Any cells which have only one candidate can safely be assigned that value.  It is very important whenever a value is assigned to a cell, that this value is also excluded as a candidate from all other blank cells sharing the same row, column and box 12 INTELLIGENT SUDOKU SOLVER
  • 13.  NAKED SINGLE 13 INTELLIGENT SUDOKU SOLVER VIII. PATTERNS
  • 14.  NAKED PAIR  A Naked Pair (also known as a Conjugate Pair) is a set of two candidate numbers sited in two cells that belong to at least one unit in common. That is they reside in the same row, box or column. 14 INTELLIGENT SUDOKU SOLVER VIII. PATTERNS
  • 15. IX. PATTERNS  NAKED PAIR 15 INTELLIGENT SUDOKU SOLVER
  • 16.  HIDDEN SINGLE  Very frequently, there is only one candidate for a given row, column or box, but it is hidden among other candidates.  In the example on the right, the candidate 6 is only found in the middle right cell of the 3x3 box. Since every box must have a 6, this cell must be that 6. 16 INTELLIGENT SUDOKU SOLVER VIII. PATTERNS
  • 17.  Locked Candidates -I  Sometimes a candidate within a box is restricted to one row or column. Since one of these cells must contain that specific candidate, the candidate can safely be excluded from the remaining cells in that row or column outside of the box. VIII. PATTERNS INTELLIGENT SUDOKU SOLVER
  • 18.  Locked Candidates – I Example In the example above, the right box only has candidate 2's in its bottom row. Since, one of those cells must be a 2, no cells in that row outside that box can be a 2. Therefore 2 can be excluded as a candidate from the highlighted cells. VIII. PATTERNS INTELLIGENT SUDOKU SOLVER
  • 19.  Locked Candidates – II  Sometimes a candidate within a row or column is restricted to one box. Since one of these cells must contain that specific candidate, the candidate can safely be excluded from the remaining cells in the box. VIII. PATTERNS INTELLIGENT SUDOKU SOLVER
  • 20.  Locked Candidates – II Example In the example on the right, the left column has candidate 9's only in the middle box. Therefore, since one of these cells must be a 9 (otherwise the column would be without a 9), 9's can safely be excluded from all cells in this middle box except those in the left column. VIII. PATTERNS INTELLIGENT SUDOKU SOLVER
  • 21. IX. DESIGN (FLOW CHART) 21 INTELLIGENT SUDOKU SOLVER Yes No Yes No Reading Sudoku from a file Search patterns Take necessary action Solved? Print Solution Stop Start Make a smart guess Found
  • 22. X. FEATURES  A Java based Sudoku Solver  Benchmarked at solving 49151 random puzzles within 16159 milliseconds.  Used optimized pattern detection strategies like Naked Singles, Hidden  Singles and Locked Candidates to aid solving.  Reviewed the performance of our solver with existing Sudoku Solvers in the world.  Comprehensive statistical and graphical results to record the solver's performance using JFreeChart API. INTELLIGENT SUDOKU SOLVER
  • 23. We conducted a test on some of the world’s popular and fastest Sudoku solvers. The test consisted of solving 1000 very hard puzzles. We fed the same set of 1000 puzzles to all solvers and result is here…. INTELLIGENT SUDOKU SOLVER
  • 24. OUR OPPONENT…. … a puzzle took 15.5 billion nanoseconds!!! INTELLIGENT SUDOKU SOLVER
  • 25. OUR INTELLIGENT SOLVER…. … a puzzle took 25 million nanoseconds!!! INTELLIGENT SUDOKU SOLVER
  • 26. NO COMPARISON!!! … can’t compare millions with billions!!! INTELLIGENT SUDOKU SOLVER
  • 27. NO COMPARISON!!! … can’t compare millions with billions!!! INTELLIGENT SUDOKU SOLVER
  • 28. XI. CODE SNIPPETS INTELLIGENT SUDOKU SOLVER 28
  • 30. XI. CODE SNIPPETS INTELLIGENT SUDOKU SOLVER 30
  • 31.
  • 32. XI. CODE SNIPPETS INTELLIGENT SUDOKU SOLVER 32
  • 33.
  • 34. Our paper titled - has been reviewed and accepted by International Journal of Scientific Research and Publications and will be published in Volume 3, Issue 5, May 2013. INTELLIGENT SUDOKU SOLVER
  • 35. THANK YOU  We would like to thank our project guide Dr. Sunil Patekar & Prof Mahesh Bhave for helping us identify the flaws and correcting them. We would also like to thank Assistant Professors Rugved Deolekar and Aman Mahadeshwar for their inputs. 35 INTELLIGENT SUDOKU SOLVER