Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mesher failed for the attached test #2

Open
TangLaoya opened this issue Feb 20, 2024 · 3 comments
Open

Mesher failed for the attached test #2

TangLaoya opened this issue Feb 20, 2024 · 3 comments

Comments

@TangLaoya
Copy link

Dear Rainer Reichel,

I generated a test file based on the description and found the mesher failed. Could you please help me to take a look at it?

Thanks,

Tang Laoya

offtest.txt

@rreichel86
Copy link
Owner

Dear Tang Loaya,

What are you trying to mesh?

Best Regards

Rainer Reichel

@TangLaoya
Copy link
Author

Dear Rainer Reichel,

I use the command
-i offtest.txt

Thanks,

Tang Laoya

@TangLaoya
Copy link
Author

Dear Rainer Reichel,

Can you reproduce this bug? Do you have any idea on how to solve this problem? I guess it is from here:

                        !Case 3: out-out* || out*-out
                                 
                        else if ( (( SAS .eq. -1 .and. SANR .gt. 1 )  .and. ( SES .eq. -1 .and. SENR .eq. 1))  & 
                            & .or. (( SAS .eq. -1 .and. SANR .eq. 1 )  .and. ( SES .eq. -1 .and. SENR .gt. 1))  ) then
                            
                            SQ = segment( Qtr%Boundary( Q(j) ), Qtr%Boundary( Q(j+1) ) )   
                            
                            if ( SAS .eq. -1 .and. SANR .gt. 1 ) then
                                nr1 = SANR
                                nr2 = SENR
                            else if ( SAS .eq. -1 .and. SANR .eq. 1 ) then
                                nr1 = SANR
                                nr2 = SENR
                            end if 
                            
                            call intrsc_segment_polygon (polygons(nr1), SQ, pt1, intrsc1)
                            call intrsc_segment_polygon (polygons(nr2), SQ, pt2, intrsc2)


                            ! 8.01.2017   pt1 == pt2 ?
                            if (intrsc1) then  
                                zhl = zhl + 1
                                Qtr%intrsc_points(zhl)%pos = pt1
                                Qtr%intrsc_points(zhl)%wpoly = nr1
                            end if
                            
                            if (intrsc2) then  
                                zhl = zhl + 1
                                Qtr%intrsc_points(zhl)%pos = pt2
                                Qtr%intrsc_points(zhl)%wpoly = nr2
                            end if
                            
                        !Case 4: out**-out* || out*-out**    
                        else if ( (( SAS .eq. -1 .and. SANR .gt. 1 )  .and. ( SES .eq. -1 .and. SENR .gt. 1) .and. (SANR .ne. SENR)) ) then
                            
                            SQ = segment( Qtr%Boundary( Q(j) ), Qtr%Boundary( Q(j+1) ) )   
                            
                            !if ( SAS .eq. -1 .and. SANR .gt. 1 ) then
                                nr1 = SANR
                                nr2 = SENR
                            !else if ( SAS .eq. -1 .and. SANR .eq. 1 ) then
                                !nr1 = SANR
                                !nr2 = SENR
                            !end if 
                            
                            call intrsc_segment_polygon (polygons(nr1), SQ, pt1, intrsc1)
                            call intrsc_segment_polygon (polygons(nr2), SQ, pt2, intrsc2)

                            ! 8.01.2017   pt1 == pt2 ?
                            if ( intrsc1 ) then
                                zhl = zhl + 1
                                Qtr%intrsc_points(zhl)%pos = pt1
                                Qtr%intrsc_points(zhl)%wpoly = nr1
                            end if
                            
                            if ( intrsc2) then
                                zhl = zhl + 1
                                Qtr%intrsc_points(zhl)%pos = pt2
                                Qtr%intrsc_points(zhl)%wpoly = nr2
                            end if

where the number of 'intrsc_points' (zhl) is not reached to 4 but here

                            sch = sch + 1
                            
                            temp_coor(zhl) = Qtr%intrsc_points(sch)%pos

sch reaches to 4, as a result, the zero temp_coor output.

Thanks,

Tang Laoya

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants