### Program Information

Name: Grep
Domain: Algorithm
Functionality: Searching some input files for lines containing a match to the specified pattern.
Input:
R:The regular expressions(Type: Expression)
Output:
O:All lines containing R(Type: Line

#### Reference

Metamorphic slice: An application in spectrum-based fault localization http://dx.doi.org/10.1016/j.infsof.2012.08.008

### MR Information

#### MR1

Source input: $R_s$ ; Source output: $R_f$
Follow-up input: $O_s$ ; Follow-up output: $O_f$
Input relation: $R_s=[x_{1} \cdots x_n] \qquad or \qquad [x_{1}-x_n]$ $R_f=x_{1}| \cdots |x_n$, where the symbol “$\mid$” means “or”.
Output relation: $O_f = O_s$

#### MR2

Source input: $R_s$ ; Source output: $R_f$
Follow-up input: $O_s$ ; Follow-up output: $O_f$
Input relation: $R_s=[x_{1} \cdots x_n] \qquad or \qquad [x_{1}-x_n]$ $R_f=[x_{1} \cdots x_m]|[x_{m+1} - x_n]$, where $[x1\cdots x_m]$ and $[x_{m+1} - x_n]$ is sub-expression in $R_s$, and the symbol “$\mid$” means to split the bracket into two brackets.
Output relation: $O_f = O_s$

#### MR3

Source input: $R_s$ ; Source output: $R_f$
Follow-up input: $O_s$ ; Follow-up output: $O_f$
Input relation: $R_s=[x_{1} \cdots x_n] \qquad or \qquad [x_{1}-x_n]$ $R_f=[x_{1} \cdots x_{i-1} [x_i][x_{i+1}] \cdots [x_{i+m}] x_{i+m+1} \cdots x_n]$
Output relation: $O_f = O_s$

### Related

Insert title here