🇮🇳 GATE DA & AI Engineering · subject
GATE DA & AI Engineering AI Syllabus
The AI syllabus for GATE DA & AI Engineering in full: 3 chapters and 8 topics, every one listed below, plus 64 AI flashcards with answers.
AI syllabus: all 3 chapters
Expand any chapter to see its topics and sub-topics.
-
Search
3 topics- Informed Search
- Uninformed Search
- Adversarial Search
-
Logic
2 topics- Propositional Logic
- Predicate Logic
-
Reasoning Under Uncertainty
3 topics- Conditional Independence Representation
- Exact Inference through Variable Elimination
- Approximate Inference through Sampling
GATE DA & AI Engineering AI flashcards — 64 questions with answers
What is the difference between informed (heuristic) search and uninformed (blind) search?
Uninformed search uses only the problem definition (no domain knowledge beyond goal test and successors), e.g. BFS, DFS, UCS. Informed search uses a problem-specific heuristic function $h(n)$ that estimates the cost from node $n$ to the goal, guiding the search toward promising nodes.
Define the heuristic function $h(n)$ and evaluation function $f(n)$ used in best-first search.
$h(n)$ estimates the cheapest cost of the path from node $n$ to a goal. $f(n)$ is the node-ordering function used to select which node to expand; the frontier is a priority queue ordered by $f(n)$ (smaller first).
What evaluation function does Greedy Best-First Search use, and is it optimal or complete?
It uses $f(n) = h(n)$ (expands the node that appears closest to the goal). It is neither optimal nor complete in general (can get stuck in loops in graph form it is complete in finite spaces, but still not optimal).
State the A* search evaluation function and the meaning of each term.
$$f(n) = g(n) + h(n)$$ where $g(n)$ is the actual cost from the start node to $n$, and $h(n)$ is the estimated cost from $n$ to the goal. A* expands the node with the lowest $f(n)$.
What is an admissible heuristic, and what does it guarantee in A*?
A heuristic is admissible if it never overestimates the true cost to the goal: $h(n) \leq h^{*}(n)$ for all $n$, where $h^{*}(n)$ is the true optimal cost. Admissibility guarantees that tree-search A* is optimal.
Define a consistent (monotone) heuristic and give the condition for consistency.
A heuristic $h$ is consistent if for every node $n$ and every successor $n'$ generated by action $a$ with step cost $c(n,a,n')$: $$h(n) \leq c(n,a,n') + h(n')$$ Consistency implies admissibility and guarantees graph-search A* is optimal (with non-decreasing $f$ along any path).
Compare the relationship between consistency and admissibility of heuristics.
Every consistent heuristic is admissible, but not every admissible heuristic is consistent. Consistency is the stronger condition needed to guarantee optimality of A* in graph search.
What does it mean for heuristic $h_2$ to dominate $h_1$, and why is dominance desirable?
$h_2$ dominates $h_1$ if $h_2(n) \geq h_1(n)$ for all $n$ (both admissible). Dominance is desirable because a higher admissible heuristic expands fewer nodes, so $h_2$ is never less efficient than $h_1$.
How can an admissible heuristic be derived from a relaxed problem?
By removing restrictions on actions, you create a relaxed problem whose optimal solution cost is an admissible (and consistent) heuristic for the original problem, because any solution to the original is also a solution to the relaxed problem.
What is Iterative-Deepening A* (IDA*) and what does it improve over A*?
IDA* performs depth-first searches with an increasing cutoff on $f(n)$ rather than depth. Each iteration's cutoff is the smallest $f$ value that exceeded the previous cutoff. It reduces A*'s memory use to linear while remaining optimal with an admissible heuristic.
List the four standard criteria used to evaluate any search algorithm.
Completeness (does it always find a solution if one exists?), Optimality (does it find the least-cost solution?), Time complexity (number of nodes generated), and Space complexity (maximum number of nodes in memory).
Describe Breadth-First Search (BFS): data structure, completeness, and optimality.
BFS expands the shallowest unexpanded node using a FIFO queue. It is complete (if branching factor $b$ is finite) and optimal when all step costs are equal. Time and space complexity are $O(b^{d})$ where $d$ is the depth of the shallowest goal.
Give the time and space complexity of Breadth-First Search and explain its main drawback.
Both time and space are $O(b^{d})$. The main drawback is memory: BFS must store every generated node in the frontier, so exponential memory usually exhausts before time does.
Describe Uniform-Cost Search (UCS): ordering rule and optimality condition.
UCS expands the node with the lowest path cost $g(n)$ using a priority queue. It is complete and optimal for any step costs $\geq \epsilon > 0$ (non-negative). It is essentially A* with $h(n)=0$ (Dijkstra's algorithm).
What is the worst-case time/space complexity of Uniform-Cost Search in terms of cost?
$$O\!\left(b^{1 + \lfloor C^{*}/\epsilon \rfloor}\right)$$ where $C^{*}$ is the optimal solution cost and $\epsilon$ is the minimum step cost. This can be much greater than $b^{d}$.
Describe Depth-First Search (DFS): data structure, completeness, optimality, and space complexity.
DFS expands the deepest node using a LIFO stack. It is not optimal and not complete in infinite or looping spaces (complete only for finite graph search). Its key advantage is space complexity $O(bm)$, where $m$ is the maximum depth; time is $O(b^{m})$.
What is Depth-Limited Search and what problem does it address?
DFS with a predetermined depth limit $\ell$: nodes at depth $\ell$ have no successors. It addresses DFS's failure in infinite-depth spaces, but is incomplete if $\ell < d$ and non-optimal if $\ell > d$.
Describe Iterative Deepening Search (IDS) and why it is often preferred for uninformed search.
IDS runs depth-limited search with increasing limits $\ell = 0, 1, 2, \dots$ until a goal is found. It combines DFS's space efficiency $O(bd)$ with BFS's completeness and optimality (equal step costs). Time is $O(b^{d})$; repeated work is negligible because lower levels are small.
What is Bidirectional Search and what is its main complexity advantage?
Two simultaneous searches run forward from the start and backward from the goal, stopping when frontiers meet. Time and space complexity reduce to roughly $O(b^{d/2})$, which is much smaller than $O(b^{d})$.
In a search problem, distinguish 'tree search' from 'graph search'.
Tree search does not remember visited states and may re-expand them (risking infinite loops). Graph search keeps an explored/closed set so each state is expanded at most once, avoiding redundant paths and loops.
Show the other 44 AI flashcards
What is the goal of adversarial search, and what defines a zero-sum two-player game?
Adversarial search finds optimal moves in competitive multi-agent environments. A zero-sum two-player game is one where the players' utilities are exactly opposed: one player's gain equals the other's loss, so utilities sum to a constant (e.g., $+1$ and $-1$).
State the minimax value recurrence for a game with MAX and MIN players.
$$\text{MINIMAX}(s) = \begin{cases} \text{UTILITY}(s) & \text{if } s \text{ is terminal} \\ \max_{a} \text{MINIMAX}(\text{RESULT}(s,a)) & \text{if MAX to move} \\ \min_{a} \text{MINIMAX}(\text{RESULT}(s,a)) & \text{if MIN to move} \end{cases}$$
Give the time and space complexity of the minimax algorithm for a game with branching factor $b$ and depth $m$.
Time complexity is $O(b^{m})$ and space complexity is $O(bm)$ (it performs a depth-first exploration of the game tree).
What is alpha-beta pruning and what do $\alpha$ and $\beta$ represent?
Alpha-beta pruning eliminates branches that cannot affect the minimax decision. $\alpha$ is the best (highest) value found so far for MAX along the path; $\beta$ is the best (lowest) value found so far for MIN. A branch is pruned when $\alpha \geq \beta$.
How much can optimal move ordering improve alpha-beta pruning's complexity?
With perfect move ordering, alpha-beta examines only $O(b^{m/2})$ nodes instead of $O(b^{m})$, effectively reducing the branching factor to $\sqrt{b}$ and doubling the searchable depth.
Why are evaluation functions and cutoff tests used in game-playing programs?
Because full search to terminal states is infeasible, search is cut off at a depth limit and a heuristic evaluation function estimates the expected utility of non-terminal states (e.g., a weighted sum of features), replacing the true utility.
What is expectiminimax and when is it used?
Expectiminimax extends minimax to games with chance nodes (e.g., dice). At chance nodes the value is the expected value over outcomes: $$\text{EXPECTIMINIMAX}(s) = \sum_{r} P(r)\,\text{EXPECTIMINIMAX}(\text{RESULT}(s,r))$$ used for stochastic games like backgammon.
Define a literal, clause, and conjunctive normal form (CNF) in propositional logic.
A literal is an atomic proposition or its negation (e.g., $P$ or $\neg P$). A clause is a disjunction of literals (e.g., $P \lor \neg Q \lor R$). CNF is a conjunction of clauses, i.e., an AND of ORs.
Define the terms valid, satisfiable, and unsatisfiable for a propositional sentence.
A sentence is valid (a tautology) if true in every model; satisfiable if true in at least one model; unsatisfiable (a contradiction) if true in no model. A sentence is valid iff its negation is unsatisfiable.
State the deduction theorem connecting entailment and validity.
$\alpha \models \beta$ if and only if the sentence $(\alpha \Rightarrow \beta)$ is valid. Equivalently, $\alpha \models \beta$ iff $(\alpha \land \neg\beta)$ is unsatisfiable (proof by refutation).
Write the logical equivalences for implication elimination and the contrapositive.
Implication elimination: $(\alpha \Rightarrow \beta) \equiv (\neg\alpha \lor \beta)$. Contrapositive: $(\alpha \Rightarrow \beta) \equiv (\neg\beta \Rightarrow \neg\alpha)$.
State De Morgan's laws in propositional logic.
$$\neg(\alpha \land \beta) \equiv (\neg\alpha \lor \neg\beta)$$ $$\neg(\alpha \lor \beta) \equiv (\neg\alpha \land \neg\beta)$$
State the propositional resolution inference rule.
From two clauses containing complementary literals, infer their resolvent (the disjunction of all remaining literals): $$\frac{\ell_1 \lor \dots \lor \ell_k \lor m, \quad n_1 \lor \dots \lor n_j \lor \neg m}{\ell_1 \lor \dots \lor \ell_k \lor n_1 \lor \dots \lor n_j}$$ Resolution is sound and refutation-complete for propositional logic.
What is Modus Ponens, and is it sound?
Modus Ponens: $$\frac{\alpha \Rightarrow \beta, \quad \alpha}{\beta}$$ Given an implication and its antecedent, infer the consequent. It is a sound inference rule.
What is a Horn clause, and why is it computationally important?
A Horn clause is a disjunction of literals with at most one positive literal (equivalently, an implication with a conjunction of positive premises and a single positive conclusion). Inference on Horn clauses can be done in linear time using forward or backward chaining.
What two elements do predicate (first-order) logic add beyond propositional logic?
First-order logic adds (1) objects, relations, and functions over a domain (terms and predicates) and (2) quantifiers: the universal quantifier $\forall$ and the existential quantifier $\exists$, allowing statements about all or some objects.
What is the difference between the universal quantifier $\forall$ and the existential quantifier $\exists$, and which connective naturally pairs with each?
$\forall x\, P(x)$ asserts $P$ holds for every object; it naturally pairs with implication ($\forall x\, (At(x) \Rightarrow \dots)$). $\exists x\, P(x)$ asserts $P$ holds for at least one object; it naturally pairs with conjunction ($\exists x\, (At(x) \land \dots)$).
State the duality between universal and existential quantifiers using negation.
$$\neg \forall x\, P(x) \equiv \exists x\, \neg P(x)$$ $$\neg \exists x\, P(x) \equiv \forall x\, \neg P(x)$$ Each quantifier can be expressed via the other with negation (De Morgan for quantifiers).
State the rules of Universal Instantiation (UI) and Existential Instantiation (EI).
UI: from $\forall x\, \alpha$ infer $\text{SUBST}(\{x/g\}, \alpha)$ for any ground term $g$. EI: from $\exists x\, \alpha$ infer $\text{SUBST}(\{x/k\}, \alpha)$ where $k$ is a new Skolem constant not appearing elsewhere.
What is unification, and what does the most general unifier (MGU) provide?
Unification finds a substitution $\theta$ that makes two logical expressions identical: $\text{UNIFY}(p, q) = \theta$ where $p\theta = q\theta$. The MGU is the least-constraining such substitution, unique up to renaming.
State the Generalized Modus Ponens rule for first-order logic.
For atomic sentences $p_i$, $p_i'$ and conclusion $q$ with substitution $\theta$ where $p_i'\theta = p_i\theta$ for all $i$: $$\frac{p_1', \dots, p_n', \quad (p_1 \land \dots \land p_n \Rightarrow q)}{q\theta}$$
What is Skolemization and why is it used?
Skolemization removes existential quantifiers when converting first-order sentences to CNF. An $\exists$ variable inside the scope of $\forall$ variables is replaced by a Skolem function of those universals (or a Skolem constant if no enclosing $\forall$), preserving satisfiability.
Define conditional independence of random variables $X$ and $Y$ given $Z$.
$X$ and $Y$ are conditionally independent given $Z$, written $X \perp Y \mid Z$, if $$P(X, Y \mid Z) = P(X \mid Z)\,P(Y \mid Z)$$ equivalently $P(X \mid Y, Z) = P(X \mid Z)$ whenever $P(Z) > 0$.
How does a Bayesian network factorize the full joint distribution?
A Bayesian network factorizes the joint as the product of each variable's conditional probability given its parents: $$P(X_1, \dots, X_n) = \prod_{i=1}^{n} P(X_i \mid \text{Parents}(X_i))$$
State the local Markov property (local semantics) of a Bayesian network.
Each variable is conditionally independent of its non-descendants given its parents: $$X_i \perp \text{NonDescendants}(X_i) \mid \text{Parents}(X_i)$$
What is a node's Markov blanket in a Bayesian network, and what is its key property?
A node's Markov blanket consists of its parents, its children, and its children's other parents. Given its Markov blanket, a node is conditionally independent of all other nodes in the network.
In d-separation, describe the three connection types and when each blocks the path.
Chain $X \to Z \to Y$ and fork $X \leftarrow Z \to Y$: blocked when $Z$ is observed. Collider (v-structure) $X \to Z \leftarrow Y$: blocked when $Z$ AND all its descendants are unobserved; observing $Z$ or a descendant unblocks (activates) the path.
For a Boolean Bayes net node with $k$ Boolean parents, how many independent parameters does its CPT require?
$2^{k}$ independent parameters (one probability per combination of the $k$ parents' values; the complementary value is determined). This exponential growth in $k$ motivates compact representations like noisy-OR.
What is the noisy-OR model and how many parameters does it need for $k$ parents?
Noisy-OR models a variable that is true if any parent is true, except each parent's effect can be independently inhibited with probability $q_i$. It needs only $k$ parameters: $$P(\neg X \mid \text{parents}) = \prod_{i:\, \text{parent}_i = \text{true}} q_i$$
What is the purpose of exact inference, and what query does Variable Elimination compute?
Exact inference computes the posterior distribution of query variables given evidence: $P(X \mid \mathbf{e})$. Variable Elimination computes this exactly by summing out non-query, non-evidence (hidden) variables from the factorized joint.
Describe the two core operations of the Variable Elimination algorithm.
(1) Pointwise product of factors: combine all factors containing a variable into one factor. (2) Summing out (marginalization): sum the resulting factor over the values of the variable to be eliminated, producing a new factor over the remaining variables.
Write the Variable Elimination expression for the query $P(X \mid \mathbf{e})$ in a Bayes net.
$$P(X \mid \mathbf{e}) = \alpha \sum_{y_1} \cdots \sum_{y_k} \prod_{i} f_i$$ where the $y_j$ are hidden variables, the $f_i$ are factors from the CPTs (with evidence fixed), and $\alpha$ is the normalization constant.
Why does Variable Elimination outperform naive enumeration, and what controls its complexity?
VE avoids repeated computation by storing intermediate factors (dynamic programming) and summing out variables early rather than enumerating the full joint. Its time/space complexity is exponential in the network's treewidth (induced width), which depends on the elimination ordering.
How does the elimination ordering affect Variable Elimination, and is finding the optimal order easy?
The ordering determines the size of intermediate factors and thus overall cost. A good order keeps factors small; a bad order can create huge factors. Finding the optimal elimination ordering is NP-hard, so heuristics (e.g., min-degree, min-fill) are used.
What does it mean to 'sum out' a variable, and what role does normalization with $\alpha$ play?
Summing out variable $Y$ replaces a factor $f(X, Y)$ with $f'(X) = \sum_y f(X, y)$, marginalizing $Y$ away. The constant $\alpha = 1 / \sum_x P(x, \mathbf{e})$ normalizes the final unnormalized factor so the posterior sums to 1.
Why are approximate (sampling) inference methods used instead of exact inference?
Exact inference (e.g., variable elimination) is #P-hard and intractable for large, densely connected networks (large treewidth). Sampling methods (Monte Carlo) trade exactness for tractability, approximating posteriors from randomly generated samples.
Describe Direct (Prior) Sampling from a Bayesian network.
Sample each variable in topological order, drawing each $X_i$ from $P(X_i \mid \text{parents}(X_i))$ using already-sampled parent values. The fraction of samples matching an event estimates its prior probability, converging to the true value as $N \to \infty$.
What is Rejection Sampling and its main weakness?
Rejection sampling generates samples by prior sampling, discards (rejects) all samples inconsistent with the evidence $\mathbf{e}$, and estimates $P(X \mid \mathbf{e})$ from the accepted samples. Its weakness: it rejects most samples when evidence is unlikely, becoming very inefficient for low-probability evidence.
Explain Likelihood Weighting and how the weight is computed.
Likelihood weighting fixes evidence variables to their observed values and samples only non-evidence variables. Each sample is weighted by the likelihood of the evidence given its parents: $$w = \prod_{i \in \text{evidence}} P(e_i \mid \text{parents}(E_i))$$ Weighted samples estimate the posterior, avoiding rejection.
What advantage and limitation does Likelihood Weighting have compared to Rejection Sampling?
Advantage: it uses every sample (no rejection), so it is far more efficient, especially with unlikely evidence. Limitation: performance degrades when there are many evidence variables, because most weights become very small (a few samples dominate), increasing variance.
Describe Gibbs sampling as an MCMC method for Bayes net inference.
Gibbs sampling is a Markov Chain Monte Carlo method: it fixes evidence, initializes other variables randomly, then repeatedly resamples each non-evidence variable from its conditional distribution given its Markov blanket. The stationary distribution of the chain is the true posterior $P(X \mid \mathbf{e})$.
In Gibbs sampling, what is each non-evidence variable resampled from, and what is 'burn-in'?
Each variable is resampled from $P(X_i \mid \text{MarkovBlanket}(X_i))$, which depends only on its parents, children, and children's parents. Burn-in is the initial set of samples discarded before the chain converges to its stationary distribution, so they do not bias the estimate.
What general convergence guarantee do Monte Carlo sampling methods provide, and at what rate?
They are consistent: estimates converge to the true probability as the number of samples $N \to \infty$ (law of large numbers). The standard error decreases at rate $O(1/\sqrt{N})$, independent of the number of dimensions.
Compare exact inference (Variable Elimination) and approximate inference (sampling) in terms of accuracy and scalability.
Variable Elimination gives exact answers but its cost is exponential in treewidth, so it fails on large dense networks. Sampling gives approximate answers with controllable accuracy (more samples = better), scales to large networks, and trades exactness for tractability.
GATE DA & AI Engineering AI FAQ
What is in the GATE DA & AI Engineering AI syllabus?
GATE DA & AI Engineering AI is split into 3 chapters: Search, Logic and Reasoning Under Uncertainty. Together they contain 8 topics.
How many chapters are in GATE DA & AI Engineering AI?
3 chapters, containing 8 topics. The largest chapter is Search, with 3 topics.
Are there flashcards for GATE DA & AI Engineering AI?
Yes — a 64-card AI deck, printed in full in the flashcards section of this page and available in the Examius app with spaced repetition. The free plan covers one exam of your choice, including its flashcards; Examius Pro, a one-time purchase, unlocks every other exam and deck.