
Explore artificial intelligence in Java, covering graph algorithms, pathfinding, optimization, and metaheuristics, plus minimax and two-player game strategies, including Tic-Tac-Toe.
Discover how artificial intelligence energizes robotics, optimization, and games, from search algorithms to neural networks. Explore meta-heuristics like genetic algorithms and simulated annealing tackling hard problems.
See why artificial intelligence relies on graph algorithms to solve problems via path finding. Apply this to games, robotics, and game trees with breadth first search and star search.
Explore breadth-first search as a graph traversal algorithm that visits each vertex once using a queue, analyzes complexity O(V+E) and memory tradeoffs, and constructs shortest paths in unweighted graphs.
Implement breadth-first search by creating a vertex class with a name, visited flag, and adjacency list, then traverse from a root using a queue to visit neighbors layer by layer.
Explore how breadth-first search enables pathfinding, maximum flow via augmenting paths (edmund scarp algorithm), and garbage collection, including reference counting, chain algorithms, and tree-like structures serialization.
Explore depth-first search, a graph traversal that visits each vertex exactly once by exploring as far as possible along a branch before backtracking, using stacks or recursion.
Learn to implement depth first search in Java using a stack and an adjacency list to traverse graphs, handle multiple clusters, and print visited vertices.
Implement depth-first search in Java using recursion, removing the stack, visiting unvisited neighbors, printing vertices, and handling multiple graph components.
Visualize depth-first search as recursive calls and stack frames starting from vertex A. See leftmost unvisited neighbors, green visits, and backtracking through D, E, B, and C.
Compare memory usage of breadth-first search and depth-first search in graph traversal: breadth-first uses linear memory, while depth-first consumes memory proportional to the tree height, about log2(n) for balanced trees.
Explore the applications of depth-first search for pathfinding, topological ordering, and detecting strongly connected components, with uses in video recommendations and social networks, and cycle detection to prevent deadlocks.
Explore the maze problem's theoretical background, using backtracking with depth-first search on an n by n board with obstacles, and learn how Trémeau relates to this approach.
Implement a maze solver in Java using a two-dimensional map, where walls are 1 and paths 0, and use depth-first search with backtracking to reach the last cell.
Explore a 4x4 maze using a recursive depth-first approach. Visualize stack frames as you move right or down, mark visited cells, and backtrack to reach the destination.
Explore iterative deepening depth-first search, merging depth-first memory efficiency with breadth-first reach in well-balanced trees. Learn how depth bounds enable repeated depth-first search across layers with linear time in practice.
Implement iterative deepening depth-first search in Java by modeling nodes with names, a depth level, and an adjacency list, and iteratively deepen until the target is found.
Learn how the A* search algorithm uses a cost function and a heuristic to find the shortest path on grid maps, balancing g-cost and h estimates with Manhattan or Euclidean distances.
Explore a concrete A* search on a grid, using g, h, and f values, with diagonal moves costing 14 and orthogonal moves costing 10, from red to green.
Implement the A* search in Java on a directed, weighted graph; build edge, node, and comparator classes to find the path from A to F via B, C, E, G.
Implement the a* search by using a source and destination, an explored hash set, and a frontier priority queue; compute g, h, and f to find the shortest path.
Implement and test an A* search on a weighted graph with coordinates, using a heuristic to guide the path from A to F and reveal the path A–B–C–E–G–F.
Explore pathfinding algorithms through a hands-on test, comparing breadth first search, A star search, Baskas and dash, and showing shortest-path computation from the starting vertex to every vertex.
Explore optimization with brute force search to find minima or maxima of a cost function, noting combinatorial explosion and future topics like hill climbing and metaheuristics.
Explore brute force search by implementing a cost function and scanning a discretized interval to find a maximum, highlighting why this approach is slow and paving the way to metaheuristics.
Explore the hill climbing algorithm, a local search method that moves toward higher values to find maxima or lower values for minima, risking local optima on non-convex functions.
Implement hill climbing on a non-convex cost function, show how start position affects global vs local maxima, and note alternatives like simulated annealing, genetic algorithms, and particle swarm optimization.
Explore NP-hard and NP-complete optimization with meta-heuristics and heuristics, comparing exact backtracking to approximate methods like genetic algorithms, simulated annealing, tabu search, and swarm optimization for the traveling salesman problem.
This course is about the fundamental concepts of artificial intelligence. This topic is getting very hot nowadays because these learning algorithms can be used in several fields from software engineering to investment banking. Learning algorithms can recognize patterns which can help detecting cancer for example. We may construct algorithms that can have a very good guess about stock price movement in the market.
- PATHFINDING ALGORITHMS -
Section 1 - Breadth-First Search (BFS)
what is breadth-first search algorithm
why to use graph algorithms in AI
Section 2 - Depth-First Search (DFS)
what is depth-first search algorithm
implementation with iteration and with recursion
depth-first search stack memory visualization
maze escape application
Section 3 - Iterative Deepening Depth-First Search (IDDFS)
what is iterative deepening depth-first search algorithm
Section 4 - A* Search Algorithm
what is A* search algorithm
what is the difference between Dijkstra's algorithm and A* search
what is a heuristic
Manhattan distance and Euclidean distance
- OPTIMIZATION -
Section 5 - Optimization Approaches
basic optimization algorithms
brute-force search
hill climbing algorithm
- META-HEURISTICS -
Section 6 - Simulated Annealing
what is simulated annealing
how to find the extremum of functions
how to solve combinatorial optimization problems
travelling salesman problem (TSP)
Section 7 - Genetic Algorithms
what are genetic algorithms
artificial evolution and natural selection
crossover and mutation
solving the knapsack problem
Section 8 - Particle Swarm Optimization (PSO)
what is swarm intelligence
what is the Particle Swarm Optimization algorithm
- GAMES AND GAME TREES -
Section 9 - Game Trees
what are game trees
how to construct game trees
Section 10 - Minimax Algorithm and Game Engines
what is the minimax algorithm
what is the problem with game trees?
using the alpha-beta pruning approach
chess problem
Section 11 - Tic Tac Toe with Minimax
Tic Tac Toe game and its implementation
using minimax algorithm
In the first chapter we are going to talk about the basic graph algorithms. Several advanced algorithms can be solved with the help of graphs, so as far as I am concerned these algorithms are the first steps.
Second chapter is about local search: finding minimum and maximum or global optimum in the main. These searches are used frequently when we use regression for example and want to find the parameters for the fit. We will consider basic concepts as well as the more advanced algorithms: heuristics and meta-heuristics.
The last topic will be about minimax algorithm and how to use this technique in games such as chess or tic-tac-toe, how to build and construct a game tree, how to analyze these kinds of tree like structures and so on. We will implement the tic-tac-toe game together in the end.
Thanks for joining the course, let's get started!