CS401A's Pre-Finals: Design & Analysis of Algrthms. Module 04 Flashcards
For pre-final and final exams. (49 cards)
Definition of || What is
- It is also known as “proof by exhaustion.”
Brute-Force Algorithm || Brute Force Algorithm Design Technique?
Definition of Brute-Force Algorithm
What is Brute Force Algorithm Design Technique?
* It is also known as
“proof by exhaustion.”
Definition of || What is
- It is a method of mathematical proof in which the statement to be proved is split into a finite number of cases or sets of equivalent cases, where each type of case is checked to see if the proposition in question holds.
Brute-Force Algorithm || Brute Force Algorithm Design Technique?
Definition of || What is
- It is a straightforward approach to solve a problem based on the problem’s statement and definitions of the concepts involved.
Brute-Force Algorithm || Brute Force Algorithm Design Technique?
Definition of || What is
It is a straightforward approach in the sense that it specifically gives an idea of what approach to use.
Brute-Force Algorithm || Brute Force Algorithm Design Technique?
Definition of || What is
- “Force” comes from using computer power, not intellectual power, In short, Brute Force means “just do it”.
Brute-Force Algorithm || Brute Force Algorithm Design Technique?
Definition of Brute-Force Algorithm
What is Brute Force Algorithm Design Technique?
* “\_\_\_\_\_
” comes from using computer power, not intellectual power, In short, \_\_\_\_\_ \_\_\_\_\_
means “\_\_\_\_ \_\_ \_\_
”.
Force
Brute Force
just do it
Definition of || Importance of Using
- It is applicable to a very wide variety of problems,
such as sorting, searching, string matching.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Importance of Using
- It yields reasonable algorithms of at least some practical value with no limitation on instance size.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Importance of Using
- Sometimes, a particular problem can be solved so quickly with a
\_\_\_\_\_ \_\_\_\_\_ \_\_\_\_\_\_
that it does not make sense to waste time devising a more elegant solution.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Brute Force method
Definition of || Importance of Using
- It can still be useful for solving small-size instances of a problem.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Importance of Using
- It can serve as an important theoretical or education purpose.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Strengths of
- There is wide applicability of the technique.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Strengths of
- It is simple, yields reasonable algorithms for some important problems and yields standard algorithms for simple computational tasks and graph traversal problems.
(e.g., matrix multiplication, sorting, closest-pair; convex-hull),
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Strengths of
- It is simple, yields
\_\_\_\_\_\_\_\_\_\_ \_\_\_\_\_\_\_\_\_\_
for some important problems and yields\_\_\_\_\_\_\_\_ \_\_\_\_\_\_\_\_\_\_
for simple computational tasks and graph traversal problems.
(e.g., matrix multiplication, sorting, closest-pair; convex-hull),
Brute-Force Algorithm || Brute Force Algorithm Design Technique
reasonable algorithms
standard algorithms
Definition of || Weaknesses of
- It rarely yields efficient algorithms.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Weaknesses of
- Some are unacceptably slow
(such as the recursive algorithm for computing Fibonacci numbers).
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Definition of || Weaknesses of
- It is not as constructive as some other design techniques.
Brute-Force Algorithm || Brute Force Algorithm Design Technique
Application of Brute Force Algorithm
- Sorting problem
- Searching problem
- Brute Force String Matching
- Exhaustive Search
Application of
asks to rearrange the items of a given list in ascending or descending order.
Brute Force Algorithm
Sorting problem
Application of
List of Sorting Algorithms
Brute Force Algorithm
* Selection sort
* Bubble sort
Application of
is a type of sorting algorithm in which the smallest element in the unsorted portion of a list is selected and then swapped with the element at the beginning of the sorted portion of the list. The steps are then repeated until all of the data are sorted.
Brute Force Algorithm
* Selection sort
Application of
is a type of sorting algorithm that compares the adjacent pair of elements of the list and swaps them if they are in the wrong order. The steps through the list are repeated until no more swaps are required, which indicates that the list is sorted.
Brute Force Algorithm
* Bubble sort
Application of
This shows the ‘\_\_\_\_\_\_\_\_ \_\_
’ of the largest element to the last position on the list.
Brute Force Algorithm
* Bubble sort
bubbling up