The Software IP Detective: Infringement Detection in a Nutshell
When copying has occurred, much of the code may have changed by the time it’s examined due to the normal development process or to disguise the copying. For example identifiers may have been renamed, code reordered, instructions replaced with similar instructions, and so forth. However, perhaps one comment remains the same and it’s an unusual comment. Or a small sequence of critical instructions is identical. Correlation is designed to produce a relatively high value based on that comment or that sequence, to direct the detective toward that similarity. If correlation were simply a percentage of copied lines, the number could be small and thus missed entirely among the noise of normal similarities that occur in all programs.