header
GetMid

Tag:
Edit edit   Starstar

Program Information

Name: GetMid
Domain: Numerical program
Functionality: The program is expected to return the median of three real numbers a, b, and c
Input: three numbers $a,b,c$
Output: The median of $(a,b,c)$

Reference

Metamorphic Testing and Beyond https://doi.org/10.1109/STEP.2003.18

MR Information

MR1------

Description:
Property: $Med(b,a,c)=Med(a,b,c)$
Source input: $(a,b,c)$
Source output: $Med(a,b,c)$
Follow-up input: $(b,a,c)$
Follow-up output: $Med(b,a,c)$
Input relation: $(a,b,c) \Rightarrow (b,a,c)$
Output relation: $Med(b,a,c)=Med(a,b,c)$
Pattern:

MR2------

Description:
Property: $Med(a,c,b)=Med(a,b,c)$
Source input: $(a,b,c)$
Source output: $Med(a,b,c)$
Follow-up input: $(a,c,b)$
Follow-up output: $Med(a,c,b)$
Input relation: $(a,b,c) \Rightarrow (a,c,b)$
Output relation: $Med(a,c,b)=Med(a,b,c)$
Pattern:
Insert title here