hexagon logo

measuring a countersink

Good evening Pcdmis masters, I`m fairly new to Pcdmis, and i would love to get some help , I am trying to measure a Countersink Dia at the intersection of the top surface on this part, the available area is very limited and the thread leads are not clocked to the model to get an auto cone reading accurately, is there any method i can use to first identify the rotation of the the double lead thread and then construct a cone avoiding the thread lead`s in order to get an accurate reading? any tips will be appreciated ,thanks in advance
  • There's an error in the previous post, it' an ASIN and not an ATAN !!!!! Disappointed
    ASSIGN/V1=PROBEDATA("diam","tip4")/2+PROBEDATA("prbrdv","tip4")
    ASSIGN/V2=PROBEDATA("diam","tip5")/2+PROBEDATA("prbrdv","tip5")
    ASSIGN/V3=RAD2DEG(ASIN(PT2.Z-PT1.Z)/(V2-V1))) is the angle of the chamfer


    Then the radius of the contact point are :
    ASSIGN/R1=V1*SIN(DEG2RAD(V3)
    ASSIGN/R2=V2*SIN(RAG2DEG(V3)

    The height of contact point are :
    ASSIGN/H1=PT1.Z-V1*COS(DEG2RAD(V3)
    ASSIGN/H1=PT2.Z-V2*COS(DEG2RAD(V3)


    The a 2D line (H=a R + b) should give :
    ASSIGN/A=​(H2-H1)/(R2-R1)
    So 
    ASSIGN/B=H2-A*R2



    The upper diameter of the countersick is done when H=0, so when R=-B/A

    ASSIGN/DIAM=2*(-B/A)


    Hope this helps...
  • This is absolutely beautiful, thank you so much for your help, i was actually able to follow your steps to match my needs, I will need help now assigning those variables to a generic feature to dimension it , I would assume I need to create a generic cone to then intersected to the top surface? Is that correct? Could you please review my code to make sure I'm doing it right? How do i used the results from the variables to do that? Thanks in advance.

    ASSIGN/V10=PROBEDATA("diam","T1_3X20")/2+PROBEDATA("prbrdv","T1_3X20")
                  ASSIGN/V11=PROBEDATA("diam","T6_5X20")/2+PROBEDATA("prbrdv","T6_5X20")
                  ASSIGN/V12=RAD2DEG(ASIN(PT2.Z-PT1.Z)/(V11-V10))
                  ASSIGN/R1=V10*SIN(DEG2RAD(V12))
                  ASSIGN/R2=V11*SIN(RAD2DEG(V12))
                  ASSIGN/H1=PT1.Z-V10*COS(DEG2RAD(V12))
                  ASSIGN/H2=PT2.Z-V11*COS(DEG2RAD(V12))
                  ASSIGN/A=(H2-H1)/(R2-R1)
                  ASSIGN/B=(H2-A*R2)
                  ASSIGN/DIAM=2*(-B/A)
    CS_X34.5     =GENERIC/CIRCLE,DEPENDENT,CARTESIAN,OUT,$
                  NOM/XYZ,<0,0,-0.29311>,$
                  MEAS/XYZ,<0,0,-0.29311>,$
                  NOM/IJK,<0,0,1>,$
                  MEAS/IJK,<0,0,1>,$
                  RADIUS/0,0
  • The dimension depends on the blue print.
    The top diameter can be created by a generic circle :
    ASSIGN/DIST1=DOT(PT1.XYZ-PL1.XYZ,PL1.IJK)....................distance between the centerball of PT1 and the top plane
    ASSIGN/ANGLE_AXIS=ACOS(DOT(UNIT(PT2.XYZ-PT1.XYZ,PL1.IJK)))......................angle between cone axis and top plane vector
    ASSIGN/CENTER=PT1.XYZ+(DIST1/COS(ANGLE_AXIS))*UNIT(PT2.XYZ-PT1.XYZ)......................if CENTER.Z is not zero, there's a problem !!!!!
    ASSIGN/VECT=UNIT(PT2.XYZ-PT1.XYZ)
    CS_X34.5 =GENERIC/CIRCLE,DEPENDENT,CARTESIAN,OUT,$
    NOM/XYZ,<CENTER.X,CENTER.Y,CENTER.Z>,$
    MEAS/XYZ,<CENTER.X,CENTER.Y,CENTER.Z>,$
    NOM/IJK,<0,0,1>,$
    MEAS/IJK,<VECT.I,VECT.J,VECT.K>,$
    RADIUS/(-B/A),(-B/A)


    Creating a cone is also possible, I'm not at the cmm to check...
    I think the XYZ values are the vertex coordinates
    ASSIGN/DIST2=B-DIST1
    ASSIGN/VERTEX=PT1.XYZ+(DIST2/COS(ANGLE_AXIS))*UNIT(PT2.XYZ-PT1.XYZ)......with DIST2 should be negative...

    The cone angle (half value is V3)​
    The length of the cone depends on the diameter of the threaded hole
  • ASSIGN/ANGLE_AXIS=ACOS(DOT(UNIT(PT2.XYZ-PT1.XYZ,PL1.IJK))) i must have a syntax error on this line, is highlighted red, also my center .z is .00009 , is that enough to worry? most of the assignments are returning 0 values working offline but on a program that already ran online is that normal?,thanks in advance , you are keeping me awake the entire weekend , user like you make this forum a really valuable and unlimited learning source, thanks for sharing.
  • I forgot a bracket in the assignment Disappointed
    ASSIGN/ANGLE_AXIS=ACOS(DOT(UNIT(PT2.XYZ-PT1.XYZ),PL1.IJK))
    The result of a dot product between two vectors is the product of the length of both vectors by the cosine of the angle between them.
    So if you use UNIT, the length is 1, a vector using .IJK is 1, so the dot product gives the cosine. ACOS gives the angle.

    Could you share values of center ball, so that I can check all the assignments.
    Even if 0.00009 is very small, it should be zero, so maybe I'm wrong in an assignment (I wrote this from my memory, I wasn't at the cmm... !)
  • the values for the center ball are 34.42939,.000457,.00009 , one thing i didn`t mention ,i used 3mm and 5mm as 4 was not available until this week, could be that my problem? thank you so much , i tried that bracket and it turned blue but i was not sure if it was correct, oh god this is intense Slight smile thanks for double checking.
  • ASSIGN/R1=V10*SIN(DEG2RAD(V12)) result is 0
    ASSIGN/R2=V11*SIN(RAD2DEG(V12)) result is 0
    ASSIGN/H1=PT1.Z-V10*COS(DEG2RAD(V12)) result is .10652
    ASSIGN/H2=PT2.Z-V11*COS(DEG2RAD(V12)) result is 1.89691
    ASSIGN/A=(H2-H1)/(R2-R1) result is 99999999999999
    ASSIGN/B=H2-A*R2 result is 1.89691
    ASSIGN/DIAM=2*(-B/A) result is 0
    ASSIGN/DIST1=DOT(PT1.XYZ-PLN1.XYZ,PLN1.IJK) result is .10652
    ASSIGN/ANGLE_AXIS=ACOS(DOT(UNIT(PT2.XYZ-PT1.XYZ),PL1.IJK)) result is .04216
    ASSIGN/CENTER=PT1.XYZ+(DIST1/COS(ANGLE_AXIS))*UNIT(PT2.XYZ-PT1.XYZ) result is 34.42939,.000457,.00009
    ASSIGN/VECT=UNIT(PT2.XYZ-PT1.XYZ) result is .04144,.00562,-.99913​
  • ASSIGN/V12=RAD2DEG(ASIN(PT2.Z-PT1.Z)/(V11-V10))....... here, I wrote RAD2DEG to give a result in degrees. If you don't use degrees, just write /V12=ASIN((PT2.Z-PT1.Z)/(V11-V10))
    ASSIGN/R1=V10*SIN(DEG2RAD(V12)).............so here R1=V10*SIN(V12)
    ASSIGN/R2=V11*SIN(RAD2DEG(V12)).............so here R2=V11*SIN(V12)
    and :
    ASSIGN/H1=PT1.Z-V10*COS(V12)
    ASSIGN/H2=PT2.Z-V11*COS(V12)

    Other results should change... Wink​​
  • If you want to play with, there's here an excel sheet which makes the job Wink
    autocenter cone.zip

    you just have to change values in green cells.
    Hope this helps.
  • nothing but respect to your skills in both ,Pcdmis and Math ,thank you so much for sharing, of course i will try , this is keeping me awake since i started ,have learned so much but i fell i will never stop learning , i will be taking official training in 2 weeks ,super excited thank you thank you thank you.