Skip over navigation

What is Recursion?

Terms

Introduction and Summary

What is Recursion?

Algorithm  -  A series of steps for accomplishing a set goal.
Binary Recursion  -  A recursive function which calls itself twice during the course of its execution.
Efficiency  -  How much time and space does an algorithm require to run.
Factorial  -  A mathematical function where f(n) = n * f(n-1), f(0) = 1.
Function  - 
General Case  -  The condition in a recursion function
Implementation  -  How an algorithm is actually done, programmed, coded, etc. For any algorithm, there are many ways to actually code it up, to implement it.
Iteration  -  A programming construct where looping is used to complete an action multiple times. The for() and while() constructs are prime examples of iterative constructs.
Linear Recursion  -  Recursion where only one call is made to the function from within the function (thus if we were to draw out the recursive calls, we would see a straight, or linear, path).
Exponential Recursion  -  Recursion where more than one call is made to the function from within itself. This leads to exponential growth in the number of recursive calls
Circularity  -  In terms a recursion, circularity refers to a recursive function being called with the same arguments as a previous call, leading to an endless cycle of recursion.
Memory  -  Space in the computer where information is stored.
Mutual Recursion  -  A set of functions which call themselves recursively indirectly by calling each other. For example, one might have a set of two functions, is_even() and is_odd(), each defined in terms of the other.
Nested Recursion  -  A recursive function where the argument passed to the function is the function itself.
Recursive Definition  -  A definition defined in terms of itself, either directly (explicitly using itself) or indirectly (using a function which then calls itself either directly or indirectly).
Recursion  -  A method of programming whereby a function directly or indirectly calls itself. Recursion is often presented as an alternative to iteration.
System Resources  -  Memory, disk space, CPU time, etc. Aspects of the system that only come in limited quantities. Use of resources by one application reduces the amount of these resources available to other applications (if there are three oranges on the table and I take one, that leaves only two of the three for you).
Tail Recursion  -  A recursive procedure where the recursive call is the last action to be taken by the function. Tail recursive functions are generally easy to transform into iterative functions.
Termination Condition  -  The condition upon which a recursive solution stops recurring. This terminating condition, known as the base case, is the problem in a recursive that we know how to solve explicitly, the "small" problem to which we know the answer.
Towers of Hanoi  -  A puzzle developed in 1883 by Edouard Lucas. Three poles upon which a certain number of round discs, increasing in size, are placed (all of the discs initially start on the first pole). The object of the puzzle is to move all of the discs from one pole to another pole. Only one disc can be removed from the poles at any one time, and no disc can be placed upon a larger disc.

Follow Us