Error message" floating point divide ... Log Out | Topics | Search
Moderators | Register | Edit Profile

FlexPDE User's Forum » User Postings » Error message" floating point divide by zero" « Previous Next »

Author Message
Top of pagePrevious messageNext messageBottom of page Link to this message

kim tran (kimngoc999)
Member
Username: kimngoc999

Post Number: 7
Registered: 06-2009
Posted on Tuesday, July 21, 2009 - 12:17 pm:   

Dear Mr Nelson,

I try to create a quarter of circle at each corner of the square. I was succesful to create the regions at two corner. I apply the same way for other two because they are similar way, but it doesn't work. I am not sure what wrong with that. I can't found any mistake. In the boundaries, I can't make region 6 and 8 work properly. Can you please help me with this. Thank you ( the file is attached)
application/octet-streamcircle at square corner
circle.pde (1.7 k)
Top of pagePrevious messageNext messageBottom of page Link to this message

Robert G. Nelson (rgnelson)
Moderator
Username: rgnelson

Post Number: 1278
Registered: 06-2003
Posted on Tuesday, July 21, 2009 - 05:17 pm:   

The mystery is why it ran at all!
Your regions 2, 4, etc, are not closed.
You need to put in a return arc to close the figure.

Or you can use the overlaying character of FlexPDE regions to simply overlay a small quarter-circle on a slightly larger one, as follows:
---------------------------------
region 2
START(box,-box)
Line to (box, -box+ri)
arc(center=box,-box) angle=90
line to close

region 3
START(box,-box)
Line to (box, -box+rf)
arc(center=box,-box) angle=90
line to close
-------------------------------

The active region 2 will be the narrow gap between rf and ri.
Top of pagePrevious messageNext messageBottom of page Link to this message

kim tran (kimngoc999)
Member
Username: kimngoc999

Post Number: 8
Registered: 06-2009
Posted on Wednesday, July 22, 2009 - 01:01 am:   

Thank you Robert

I have fixed my problem.

Add Your Message Here
Post:
Username: Posting Information:
This is a private posting area. Only registered users and moderators may post messages here.
Password:
Options: Enable HTML code in message
Automatically activate URLs in message
Action:

Topics | Last Day | Last Week | Tree View | Search | Help/Instructions | Program Credits Administration