Equivalence Class Partitioning
An equivalence class is defined as a subset of the form {x in X:xRa}, where a is an element of X and the notation "xRy" is used to mean that there is an equivalence relation between x and y.
An equivalence relation on a set X is a subset of XxX, i.e., a collection R of ordered pairs of elements of x, satisfying certain properties. Write xRy to mean (x,y) is an element of R, and we say x is related to Y then the properties are
- Reflexive: aRa for all a belongs to X,
- Symmetric: aRb implies bRa for all a,b belongs to X,,
- Transitive: aRb and bRc imply aRc for all a,b,c belongs to X,,
Fix a natural number n. We say that two integers a, b
are congruent modulo n if their difference is divisible by n. And if that
is the case, we write a, b (mod n) where a and b both belongs to set natural numbers with relation congruent modulo n . and output is ever an integer. Integers are in an equivalence relation set in regards of Relation.
Hence we know all input will same behavior with application but there is also limit for valid and invalid. So we looks forwards and create class in valid and invalid class.
Same as for login window
user have two input conditions.
- User ID
- Password
User Id is of two type valid and invalid.
Valid set of user id is in equivalence class because all valid user ids are created using same process and are having all the three relations.
Lets take another example:
In a computer store, the computer item can have a quantity between -500 to +500. in this case we can take any value from in
Valid class: -500 <= QTY <= +500
Invalid class: QTY > +500
Invalid class: QTY < -500
Invalid class: QTY > +500
Invalid class: QTY < -500
Comments
Post a Comment