double l_slope = (l_y4 - l_y3) / (l_x4 - l_x3); l_subtrahendCurX = l_minuendCurX; l_subtrahendCurY = new Double((l_slope * l_x1) + (l_y3 - (l_slope * l_x3))); l_subtrahendXs.add(l_subtrahendCurX); l_subtrahendYs.add(l_subtrahendCurY);
double l_slope = (l_y2 - l_y1) / (l_x2 - l_x1); l_minuendCurX = l_subtrahendCurX; l_minuendCurY = new Double((l_slope * l_x3) + (l_y1 - (l_slope * l_x1))); l_minuendXs.add(l_minuendCurX); l_minuendYs.add(l_minuendCurY);
Clone fragments detected by clone detection tool
File path: /jfreechart-1.0.10/src/org/jfree/chart/renderer/xy/XYDifferenceRenderer.java File path: /jfreechart-1.0.10/src/org/jfree/chart/renderer/xy/XYDifferenceRenderer.java
Method name: void drawItemPass0(Graphics2D, Rectangle2D, PlotRenderingInfo, XYPlot, ValueAxis, ValueAxis, XYDataset, int, int, CrosshairState) Method name: void drawItemPass0(Graphics2D, Rectangle2D, PlotRenderingInfo, XYPlot, ValueAxis, ValueAxis, XYDataset, int, int, CrosshairState)
Number of AST nodes: 5 Number of AST nodes: 5
1
double l_slope   = (l_y4 - l_y3) / (l_x4 - l_x3);
1
double l_slope = (l_y2 - l_y1) / (l_x2 - l_x1);
2
                l_subtrahendCurX = l_minuendCurX;
2
                l_minuendCurX  = l_subtrahendCurX;
3
                l_subtrahendCurY = new Double((l_slope * l_x1) 
3
                l_minuendCurY  = new Double((l_slope * l_x3) 
4
                        + (l_y3 - (l_slope * l_x3)));
4
                        + (l_y1 - (l_slope * l_x1)));
5
                l_subtrahendXs.add(l_subtrahendCurX);
5
                l_minuendXs.add(l_minuendCurX);
6
                l_subtrahendYs.add(l_subtrahendCurY);
6
                l_minuendYs.add(l_minuendCurY);
Summary
Number of common nesting structure subtrees1
Number of refactorable cases0
Number of non-refactorable cases1
Time elapsed for finding largest common nesting structure subtrees (ms)0.0
Clones locationClones are in the same method
Number of node comparisons26
  1. {Non-refactorable}
    Mapping Summary
    Number of mapped statements5
    Number of unmapped statements in the first code fragment0
    Number of unmapped statements in the second code fragment0
    Time elapsed for statement mapping (ms)0.0
    Clone typeType 2
    Mapped Statements
    ID Statement ID Statement
    88
    double l_slope = (l_y4 - l_y3) / (l_x4 - l_x3);
    88
    double l_slope = (l_y4 - l_y3) / (l_x4 - l_x3);
    94
    double l_slope = (l_y2 - l_y1) / (l_x2 - l_x1);
    Differences
    Expression1Expression2Difference
    l_y4l_y2VARIABLE_NAME_MISMATCH
    l_y3l_y1VARIABLE_NAME_MISMATCH
    l_x4l_x2VARIABLE_NAME_MISMATCH
    l_x3l_x1VARIABLE_NAME_MISMATCH
    94
    double l_slope = (l_y2 - l_y1) / (l_x2 - l_x1);
    89
    l_subtrahendCurX = l_minuendCurX;
    89
    l_subtrahendCurX = l_minuendCurX;
    95
    l_minuendCurX = l_subtrahendCurX;
    Differences
    Expression1Expression2Difference
    l_subtrahendCurXl_minuendCurXVARIABLE_NAME_MISMATCH
    l_minuendCurXl_subtrahendCurXVARIABLE_NAME_MISMATCH
    95
    l_minuendCurX = l_subtrahendCurX;
    90
    l_subtrahendCurY = new Double((l_slope * l_x1) + (l_y3 - (l_slope * l_x3)));
    90
    l_subtrahendCurY = new Double((l_slope * l_x1) + (l_y3 - (l_slope * l_x3)));
    96
    l_minuendCurY = new Double((l_slope * l_x3) + (l_y1 - (l_slope * l_x1)));
    Differences
    Expression1Expression2Difference
    l_subtrahendCurYl_minuendCurYVARIABLE_NAME_MISMATCH
    l_x1l_x3VARIABLE_NAME_MISMATCH
    l_y3l_y1VARIABLE_NAME_MISMATCH
    l_x3l_x1VARIABLE_NAME_MISMATCH
    96
    l_minuendCurY = new Double((l_slope * l_x3) + (l_y1 - (l_slope * l_x1)));
    91
    l_subtrahendXs.add(l_subtrahendCurX);
    91
    l_subtrahendXs.add(l_subtrahendCurX);
    97
    l_minuendXs.add(l_minuendCurX);
    Differences
    Expression1Expression2Difference
    l_subtrahendCurXl_minuendCurXVARIABLE_NAME_MISMATCH
    l_subtrahendXsl_minuendXsVARIABLE_NAME_MISMATCH
    97
    l_minuendXs.add(l_minuendCurX);
    92
    l_subtrahendYs.add(l_subtrahendCurY);
    92
    l_subtrahendYs.add(l_subtrahendCurY);
    98
    l_minuendYs.add(l_minuendCurY);
    Differences
    Expression1Expression2Difference
    l_subtrahendCurYl_minuendCurYVARIABLE_NAME_MISMATCH
    l_subtrahendYsl_minuendYsVARIABLE_NAME_MISMATCH
    98
    l_minuendYs.add(l_minuendCurY);
    Precondition Violations (1)
    Row Violation
    1Clone fragment #1 returns variables l_subtrahendCurX, l_subtrahendCurY , while Clone fragment #2 returns variables l_minuendCurY, l_minuendCurX