DiscussionsIssue archiveOCCT:Modeling Algorithms

Archived issue #0026009

Wrong result of the test blend bfuseblend B7

Open CASCADEOCCT:Modeling Algorithmsclosed20 public notes

Search issues

Description

After fixing the bug #25742 result of the test "blend bfuseblend B7" has been incorrect (good result is shown in the picture).

P.S.

1. This BAD result is NOT consequence of incorrect fixing. Intersection line between two given cylinders (which is the spine for blend-algorithm) has become better then before fix (tolreached has been decreased by approximately ten times). However, the result of blend algorithm has become FAIL. Most likely, the reason is labile blend algorithm.

2. On OCCT 6.7.1 test "blend bfuseblend B7" is fail. This problem was fixed (spontaneously) in the issue #25465 (see message [archived tracker link removed]).

Steps to reproduce

test blend bfuseblend B7

Public activity

20 archived notes

Participants are labeled by their role within this record.

01Commenter 2
Branch [archived branch] has been created by Author.

[revision removed]


Detailed log of new commits:

Author: Author
Date: Thu Apr 2 11:40:42 2015 +0300

    0025742: A partition of 2 shapes stresses a performance issue
    
    1. Method Dump for Blend_Point class has been added.
02Commenter 2
Branch [archived branch] has been created by Participant.

[revision removed]


Detailed log of new commits:

Author: jgv
Date: Mon Apr 27 13:10:12 2015 +0300

    0026009: Wrong result of the test blend bfuseblend B7
03Commenter 3
Please review the branch CR26009_1.
04Commenter 4
Remark:

It is possible algo hanging. Please provide checking for too small step value.
05Commenter 2
Branch [archived branch] has been updated by Participant.

[revision removed]


Detailed log of new commits:

Author: jgv
Date: Mon Apr 27 16:28:36 2015 +0300

    Correction to avoid infinite loop

06Commenter 6
Dear Mikhail,

please review corrected branch CR26009_1.
07Commenter 7
Reviewed
08Commenter 8
Look at this code:

+ hguide->D1(param, PtOnGuide, TgOnGuide);
+ //Check deflection on guide
+ Cosi = PrevTgOnGuide * TgOnGuide;
+ if (Cosi < 0.)
+ Cosi2 = 0.;
+ else
+ Cosi2 = Cosi * Cosi / PrevTgOnGuide.SquareMagnitude() / TgOnGuide.SquareMagnitude();


It may cause division by zero error if derivative is zero.
09Commenter 9
I also noted this fact, but did not pay attention to it, because thought that hguide is always well defined curve having no special points.
However, if you have a doubt I do not mind to insert a protection here, especially because it is so simple:

+ Cosi = PrevTgOnGuide * TgOnGuide;
+ if (Cosi < gp::Resolution())
+ Cosi2 = 0.;
+ else
+ Cosi2 = Cosi * Cosi / PrevTgOnGuide.SquareMagnitude() / TgOnGuide.SquareMagnitude();
10Commenter 10
Dear jgv, please make this small correction.
11Commenter 2
Branch [archived branch] has been updated by Participant.

[revision removed]


Detailed log of new commits:

Author: jgv
Date: Tue Apr 28 14:31:10 2015 +0300

    Minor correction

12Commenter 12
Thank you, Mikhail!
13Commenter 13
Please test the branch CR26009_1.
14Commenter 2
Branch [archived branch] has been updated by Participant.

[revision removed]


Detailed log of new commits:

Author: apv
Date: Wed Apr 29 15:07:53 2015 +0300

    Update of test-case for issue #0026009

15Commenter 15
Dear Commenter 1,

Branch CR26009_1 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms and tested.
[revision removed]

Number of compiler warnings:
occt component:
   Linux: 19 (18 on master)
   Windows: 2 (0 on master)
products component:
   Linux: 4 (4 on master)
   Windows: 0 (0 on master)
There are new additional warnings.
On Linux:
Blend_Walking_4.gxx:97, GNU C Compiler 4 (gcc), Priority: Normal
unused variable ‘Norme’
On Windows:
Blend_Walking_4.gxx:97, MSBuild, Priority: Normal
'Norme' : local variable is initialized but not referenced

Regressions/Differences:
Not detected

Testing cases:
blend bfuseblend(003) B7 - OK
http://occt-tests/CR26009-1-master-occt-64/Debian60-64/blend/bfuseblend/B7.html
http://occt-tests/CR26009-1-master-occt-64/Windows-64-VC10/blend/bfuseblend/B7.html

Testing on Linux:
Total MEMORY difference: 94823582 / 94606999 [+0.23%]
Total CPU difference: 51825.449999999575 / 51015.63999999946 [+1.59%]

Testing on Windows:
Total MEMORY difference: 57257797 / 57266783 [-0.02%]
Total CPU difference: 15809.000939098985 / 15810.26454719897 [-0.01%]
16Commenter 2
Branch [archived branch] has been updated by Participant.

[revision removed]


Detailed log of new commits:

Author: jgv
Date: Wed Apr 29 15:48:01 2015 +0300

    Fix of compiler's warning

17Commenter 17
Unused variable is deleted, compiler's warning disappeared.
18Commenter 18
Dear Commenter 1,

Branch CR26009_1 from occt git-repository (and master from products git-repository) was compiled on Linux, MacOS and Windows platforms and tested.
[revision removed]

Number of compiler warnings:
occt component:
   Linux: 18 (18 on master)
   Windows: 0 (0 on master)
products component:
   Linux: 4 (4 on master)
   Windows: 0 (0 on master)

Regressions/Differences:
Not detected

Testing cases:
blend bfuseblend(003) B7 - OK
http://occt-tests/CR26009-1-master-occt-64/Debian60-64/blend/bfuseblend/B7.html
http://occt-tests/CR26009-1-master-occt-64/Windows-64-VC10/blend/bfuseblend/B7.html

Testing on Linux:
Total MEMORY difference: 94735830 / 94605273 [+0.14%]
Total CPU difference: 51686.60999999931 / 51015.509999999456 [+1.32%]

Testing on Windows:
Total MEMORY difference: 57258907 / 57267962 [-0.02%]
Total CPU difference: 15903.943147699067 / 15810.29574739897 [+0.59%]
19Commenter 2
Branch [archived branch] has been deleted by Participant.

[revision removed]
20Commenter 2
Branch [archived branch] has been deleted by Participant.

[revision removed]