New Post

Markov Chains || Step-By-Step || ~xRay Pixy

Image
Learn Markov Chains step-by-step using real-life examples. Video Chapters: Markov Chains 00:00 Introduction 00:19 Topics Covered 01:49 Markov Chains Applications 02:04 Markov Property 03:18 Example 1 03:54 States, State Space, Transition Probabilities 06:17 Transition Matrix 08:17 Example 02 09:17 Example 03 10:26 Example 04 12:25 Example 05 14:16 Example 06 16:49 Example 07 18:11 Example 08 24:56 Conclusion

Objective Function Evaluation | Greedy Method | Knapsack Problem Example...

Knapsack Problem using Greedy Method


Algorithm Design Techniques
  • Divide and Conquer
  • Greedy Method
  • Dynamic Programming
  • Back Tracing
  • Branch and Bound
Divide and Conquer: Many algorithms are recursive in structure. To solve any problem, they call themselves recursively again and again [one or more times]. Three steps are followed by divide and conquer algorithms.

1.) Divide the problem into the number of sub-problems.
2.) Conquer the sub-problems by solving them recursively.
3.) Combine the solution to the sub-problems into the solution for the original problem.

The greedy method is the Straight design technique. It can be applied to a wide variety of problems. Obtain a subset that satisfies the same constraints.  Feasible Solution: If any subset satisfies these constraints. 
Our GOAL: Find a feasible solution that either Maximize or Minimize the given Objective Function. A feasible solution that does this is known as OPTIMAL SOLUTION.  A feasible Solution is any subset that satisfies these constraints.

Greedy Method Example : KNAPSACK PROBLEM
SUPPOSE: We have 
        n  = Objects and a Knapsack.
𝑤_𝑖 = Object i has weight 
 m = Knapsack Capacity

IF a fraction 𝑥_𝑖, of object i is placed into the knapsack. 0 ≤ 𝑥_𝑖 ≤ 1 than Profit Earned.
Objective: Obtain filling of Knapsack and Gain maximum profit.


n = 3;                         //Objects
m = 20;                                 //Knapsack Capacity
𝑤1,𝑤2,𝑤3 = 18, 15,10; //Objects Weight
𝑃1,𝑃2,𝑃3 = 25, 24, 15; //Profits

Comments

Popular Post

PARTICLE SWARM OPTIMIZATION ALGORITHM NUMERICAL EXAMPLE

Cuckoo Search Algorithm for Optimization Problems

Particle Swarm Optimization (PSO)

PSO (Particle Swarm Optimization) Example Step-by-Step

how is the LBP |Local Binary Pattern| values calculated? Step-by-Step with Example

PSO Python Code || Particle Swarm Optimization in Python || ~xRay Pixy

Grey Wolf Optimization Algorithm

Bat algorithm Explanation Step by Step with example

Grey Wolf Optimization Algorithm Numerical Example

Whale Optimization Algorithm Code Implementation || WOA CODE || ~xRay Pixy