Computable functions Flashcards
program output
computed as a function of program inputs and state of the machine before the program starts
effectively computable
computable with finite resources in a finite time
Undefined operation
e. g. division by zero
- may halt with error condition
non termination -
never delivers a result
- this is a partial function : not defined on all arguments
cannot be detected at compile time
functions as graphs
f: x -> y
f is a set of pair X x Y
extensional equality
two functions are equal if given the same input they yield the same output (even if they have different algorithms)
Total functions definition
the total function F:A->B os a subset B x A where for every x E A there is some y EB with E F
Also if E F and E F then y = z (single valued)
Partial function definition
the partial function F:A->B os a subset B x A where for every x E A there is some y EB with E F
Also if E F and E F then y = z (single valued)
this means that a partial function is single valued but need not be deifnied on all elements of its domain