Need to calculate these from a set of 8 results
[Spacing error not to exceed 0.005, spacing between adjacent slot 0.003, 1 place may be 0.005 max] I am using following code to calculate spacing error within 0.005, but I'm not sure how to find "
1 place may be 0.005 max"
I would highly appreciate any guidance as I need to create similar program for 60 set of slots as well.
LOC_ADJ1, 2, 3... is the spacing between adjacent slots
F1 =GENERIC/POINT,DEPENDENT,CARTESIAN,$
NOM/XYZ,<ZERO,ZERO,ZERO>,$
MEAS/XYZ,<AVG,AVG,AVG>,$
NOM/IJK,<0,0,1>,$
MEAS/IJK,<0,0,1>
DIM LOC_ADJ9= LOCATION OF POINT F1 UNITS=IN ,$
GRAPH=OFF TEXT=OFF MULT=10.00 OUTPUT=BOTH HALF ANGLE=NO
AX NOMINAL +TOL -TOL MEAS DEV OUTTOL
X 0.00000 0.00500 0.00500 0.00001 0.00001 0.00000 --#--
END OF DIMENSION LOC_ADJ9
Not sure to understand what you want...
I would :
Create a feature set with all the slots (SCN1)
Then, I would calculate the deviations along X axis in two arrays:
ASSIGN/V1=SCN1.HIT[1..(SCN1.NUMHITS-1)].X-SCN1.HIT[1..(SCN1.NUMHITS-1)].TX
ASSIGN/V2=SCN1.HIT[2..(SCN1.NUMHITS)].X-SCN1.HIT[2..(SCN1.NUMHITS)].TX
Then, I would subtract V2 to V1 to get the error spacing, and calculate the absolute value, to take into account the case of a spacing lower than -0.005 :
ASSIGN/ERROR_SP=ABS(V2-V1)
Then, I would search how many values are >= 0.005 :
ASSIGN/SEARCH_DEFECT=SUM(INT(ERROR_SP/0.005))
Then, it depends on what you have to decide...
Something like :
IF/(SEARCH_DEFECT>1) OR (MAX(ERROR_SP)>0.005)
COMMNENT/OPERATOR
THE PART IS OOT
END IF
To simplify my question
Lets say there are 8 holes with dia d1, d2, ... d8
7 dia should be within +/- 0.003
only one dia is allowed within +/- 0.005 (it can be any of 8 dia)
To simplify my question
Lets say there are 8 holes with dia d1, d2, ... d8
7 dia should be within +/- 0.003
only one dia is allowed within +/- 0.005 (it can be any of 8 dia)