Scoa U3
Scoa U3
2. Evolutionary Algorithms (EAs): Inspired by natural evolution Scope Focuses on refining Explores the search
processes like selection, mutation, and recombination. solutions near an initial space to avoid getting
guess. trapped in local optima.
● Working:
○ A population of candidate solutions (individuals) is Efficienc Faster and Slower and
initialized. y computationally less computationally
○ Each individual is evaluated using a fitness function. expensive. intensive due to a
○ The fittest individuals are selected to reproduce, broader search.
generating new solutions through crossover and
mutation. Converg May converge to a local Converges to the global
○ The process repeats for several generations, ence optimum, which is not optimum, or a
gradually evolving better solutions. necessarily the global best near-global solution,
solution. with higher certainty.
3. Particle Swarm Optimization (PSO): Mimics the behavior of a
flock of birds or fish searching for food.
Example: Traveling Salesman Problem (TSP): Find the shortest
Techniqu Gradient Descent, GA, SA, PSO
path that visits all cities exactly once and returns to the starting city.
es Used Newton's Method.
1. Initialization:
○ Start with a random tour of cities as the initial
3. Write a Simulated Annealing Algorithm and discuss with solution.
examples. ○ Set a high initial temperature T.
2. Iterative Process:
Simulated Annealing (SA) is a probabilistic optimization technique ○ Generate Neighbor Solution: Swap two cities in the
inspired by the annealing process in metallurgy. The algorithm aims current tour to create a new tour.
to find a good approximation of the global optimum of a function in a ○ Evaluate Cost: Compute the total distance of the
large search space. new tour and compare it with the current tour.
○ Acceptance Rule: Accept the new tour if it has a
Algorithm Steps: shorter distance or with a probability based on T if it
is longer.
○ Cool Down: Gradually reduce T using T=αT
Example Execution:
How It Works:
7. Discuss Evolutionary Systems as a Problem Solver. 8. What is Evolutionary Programming? Write an example.
Evolutionary Systems (or Evolutionary Algorithms) are a family of
optimization techniques inspired by the process of natural Evolutionary Programming (EP) is a type of optimization algorithm
evolution. They are used to find solutions to complex problems, inspired by biological evolution. It focuses on evolving solutions over
time to solve complex problems. It uses techniques like mutation
and selection to improve a population of candidate solutions until a 9. Write a pseudocode for evolutionary computation.
good or optimal solution is found. Unlike (GAs), EP mainly focuses 1. Initialize population P with random individuals
on mutating solutions and does not use crossover. 2. Evaluate fitness of each individual in P
3. Repeat until termination criteria are met:
How It Works: a. Select individuals from population P based on Selection -
Select parents using a method like tournament or roulette-wheel
1. Initialization: Start with a population of random solutions. selection
2. Fitness Evaluation: Measure how good each solution is. b. Create offspring through crossover: Perform crossover on
3. Mutation: Modify each solution slightly to create a new . selected parents to create new individuals
4. Selection: Choose the best solutions. c. Apply mutation to offspring: Introduce small random changes to
5. Repeat: Continue mutating and selecting solutions for offspring
multiple generations until the problem is solved. d. Evaluate the fitness of offspring
e. Replace old population P with the new population
4. Choose the best individuals from both parents and offspring for
the next generation
5. Return the best individual in the population as the solution.
11. Discuss an operation represented in the following diagram ● Exploration of Solution Space: Alters program trees to
for Genetic Programming. discover new possibilities.
● Maintaining Genetic Diversity: Prevents the population
from becoming homogeneous, avoiding local optima.
● Random Sub-tree Generation: Introduces new subtrees to
explore unexplored solution regions.