C math library: argument domain error

C math library: argument domain error

Anonymous
Not applicable
1,192 Views
7 Replies
Message 1 of 8

C math library: argument domain error

Anonymous
Not applicable

I have not come across this problem before.

 

I have imported a file into my drawing and am trying to "solid, subtract" the shape out of another solid item. Example a company logo from out of a solid material leaving a hole in the shape of the logo.

 

I'm running 2015 AutoCAD.

The part I am trying to use has been drawn using "Spline" and then "region" to form the part. I have then "Extrude" to form the thickness. When removing the part from the main body is when error message pops up

Your thoughts would be appreciated.

Regards

Testbed27

0 Likes
Accepted solutions (1)
1,193 Views
7 Replies
Replies (7)
Message 2 of 8

john.vellek
Alumni
Alumni

HI @Anonymous,

 

Can you share your file on a post? I am happy to take a look at it to see if i can get this operation to work properly.

 

 

Please select the Accept as Solution button if my post solves your issue or answers your question.


John Vellek


Join the Autodesk Customer Council - Interact with developers, provide feedback on current and future software releases, and beta test the latest software!

Autodesk Knowledge Network | Autodesk Account | Product Feedback
0 Likes
Message 3 of 8

Anonymous
Not applicable

Hi John,

I have since moved passed this as a major problem. I used an extra hour to redrew the logo using only polylines. I have had trouble with polylines verses splines in the past. Some work better than others for different tasks.

I would love to know if I have done anything odd to result in this error or if by chance I managed to find an AutoCAD bug?

Regards

Ray

0 Likes
Message 4 of 8

leeminardi
Mentor
Mentor

The splines that form the logo are very problematic.  They have excessive number of CVs and there is some corrupted data associated with them.

 

Since the logo is almost entirely straight lines and arcs it is easy to recreate the logo outline as a clean polyline.  There are 4 different radii required; 3.908, 8.759, 9.069, and 23.372.  I derived these values by drawing two chords on each of the three different arc sizes and added perpendicular bisectors to find the center of the arc.  These construction lines (green) are on the layer const in the attached drawing.

 

b1.PNG 

With osnap set to nearest I added lines for the mid section of each straight line segment.  Using chamfer (0) for where two straight segments joined at a corner and fillet I was able to complete all but the cusp in the letter B.  There I used a spline and manipulated the CV points to match the curve on layer 10mm acrylic.

I almost finished the 2D outline (it's getting late) and I thought I would leave that to you as well as extruding the final shape to a solid.  I am fairly certain this solid will behave better than the original.  The outline I created is on layer newpoly. 

b2.PNG

 

lee.minardi
0 Likes
Message 5 of 8

john.vellek
Alumni
Alumni

HI @Anonymous,

 

I saw your file but @leeminardi was so fast in doing some clean up for you that I have not gone deeper into this for you.  Did @leeminardi's drawing work for you or do you still need help? I am happy to participate further if necessary. Please let me know your status.

 

 


John Vellek


Join the Autodesk Customer Council - Interact with developers, provide feedback on current and future software releases, and beta test the latest software!

Autodesk Knowledge Network | Autodesk Account | Product Feedback
0 Likes
Message 6 of 8

Anonymous
Not applicable

Hi all,

I needed to move pretty quickly when this problem occurred so I redrew the logo only using polylines. I managed to do this before I posted the file online. I thank @leeminardi for the direction and assistance. My main focus on posting was to find out what it was that I had done to cause the problem in the first place so I can avoid doing it in the future. I have many logos that need work that don't always do what I want but I muddle my way through and this was the first C math issue. I know that true AutoCAD users would probably scoff at my methods but I usually manage the result I desire.

Once again Thank you to all that took the time to read my post and try to help. I'm not sure how to conclude this thread as the problem was not identified and my remedy was to redraw the logo so I need the resolution to say "no longer required"

Regards

Testbed27

Ray Page

0 Likes
Message 7 of 8

leeminardi
Mentor
Mentor
Accepted solution

"... find out what it was that I had done to cause the problem in the first place..,"

 

The problem appears to be in either the import method or the representation of the spline in your original non-AutoCAD source file.

 Where was the original logo modeled, what file format was used to store it and what tool was used to convert it to an AutoCAD file?  Did you use a custom C program to do part of the conversion?  If so, did you use an existing NURBS conversion function or construct one yourself from the basic equation for a NURBS?  From the appearance of the imported spline (many short segments) it looks like the source NURBS was evaluated with a small value for delta-u to determine the resulting spline chords that would be output rather than using the orignal CVs (knot vectors).  Could this be the case?  It could also be that the original logo was not a NURBS.

 

lee.minardi
0 Likes
Message 8 of 8

Anonymous
Not applicable

Hi Leeminardi,

The original was a pdf via email. I use CorelDraw to convert my pdfs into a vector file and save in the .dwg format. I then had redrawn over the top of those lines to produce a closed polyline. Due to having issues around trying to join polyline / spline together to create my usable shape I start with a rectangle and just add Vertex and then change them to a curve. It take a little longer but I then have a line that I can Offset. Many time I have lines that I can only offset on one side and it is usually the side I do not need. Anyway on this particular logo I did recreate using only polylines. I then saved the file as my "master" and imported it into my drawing. I then scaled the logo into the size I needed and somewhere between importing and scaling the lines all turned into splines and became difficult. I do have this problem regularly and I usually take the time to redraw over the top of the misbehaving lines until I can produce a shape that will REGION and then EXTRUDE into a 3D shape. I can confess to not being an very proficient user however use AutoCAD on a daily bases to produce working drawings for the workshop to build from. I still have a lot to learn but in true human style I have been only using the basics so far, but am now looking to expand my knowledge base. The C math issue was a new on to me and thank yourself and the forum for the advice.

Regards

Ray

testbed27

0 Likes