Unit 6 - Algorithms - Defined Terms

Pataasin ang iyong marka sa homework at exams ngayon gamit ang Quizwiz!

Decision problems

"Is there a path?"

Optimization problems

"What is the shortest path?"

Reasonable Time

Algorithms with a polynomial efficiency or lower (constant, linear, square, cube, etc.) are said to run in a reasonable amount of time.

Unreasonable Time

Algorithms with exponential or factorial efficiencies are examples of algorithms that run in an unreasonable amount of time. Unreasonable time algorithms can theoretically be run and will produce a correct solution. They just grow in size so quickly, even for small inputs, that it is usually unreasonable to run that algorithm.

Problems

Any task that may (or may not) be solved with an algorithm.

Selection

Deciding which steps to do next

Iteration

Doing some steps over and over

Sequencing

Putting steps in an order

Parallel

Some steps are performed at the same time.

Sequential

Steps are performed in order, one at a time.

The Halting Problem

There are some problems we've proven that no computer will ever be able to solve. The Halting Problem is a very famous example and in general we call these problems undecidable.

Algorithm

a finite set of instructions that accomplish a task. There are usually many algorithms to solve the same problem, and many ways to write or express one algorithm including natural language, psuedocode, and diagrams, and are implemented using programming code. All algorithms can be created by combining steps in three different ways.

Problem

a general description of a task that can (or cannot) be solved with an algorithm

Efficiency

a measure of how many steps are needed to complete an algorithm

Any algorithm whose efficiency includes an n2, n3, n4 ... is called

a polynomial.

Undecidable Problem

a problem for which no algorithm can be constructed that is always capable of providing a correct yes-or-no answer. Undecidable problems are a type of problem for which it has been proven that there simply is no algorithm that will always produce a correct result. The issue isn't simply that it takes a long time, but that it is demonstrably impossible to write such an algorithm.

Binary Search

a search algorithm that starts in the middle of a sorted set of numbers and removes half of the data; this process repeats until the desired value is found or all elements have been eliminated.

Linear Search

a search algorithm which checks each element of a list, in order, until the desired value is found or all elements in the list have been checked.

The Traveling Salesman Problem

an optimization problem. We are attempting to find the best path. It is also unreasonable because there is not an algorithm that can solve the problem in a reasonable amount of time. We need to use a heuristic to come up with a solution that is "good enough" for most instances of the problem.

Any algorithm whose efficiency includes an 2n, 3n, 4n ... is called

exponential.

Parallel Computing

programs are broken into small pieces, some of which are run simultaneously

Distributed Computing

programs are run by multiple devices

Sequential Computing

programs run in order, one command at a time.

Heuristics

provides a "good enough" solution to a problem when an actual solution is impractical or impossible

Speedup

the time used to complete a task sequentially divided by the time to complete a task in parallel


Kaugnay na mga set ng pag-aaral

The Inheritance Games Vocabulary #10

View Set

Module One - 2.5 Reading: Conduct Online Research

View Set