1

                                                                     EXHIBIT 11

    
                                     COGNEX CORPORATION

                            CALCULATION OF WEIGHTED AVERAGE COMMON
                            AND COMMON EQUIVALENT SHARES OUTSTANDING

Weighted average common and common share equivalents were computed as follows:


                                                     THREE MONTHS ENDED               SIX MONTHS ENDED
                                                  JUNE 30,         JULY 2,        JUNE 30,           JULY 2,
                                                   1996             1995            1996              1995
                                                ----------       ----------       ----------       ----------
                                                       (UNAUDITED)                        (UNAUDITED)
 
                                                                                              
Weighted average common shares outstanding      40,558,441       37,784,780       40,446,624       37,709,664
Weighted average options outstanding .....       6,572,834        7,661,964        6,862,869        7,738,794
Shares assumed to be purchased ...........      (3,265,072)      (4,186,292)      (3,343,468)      (4,357,560)
                                                ----------       ----------       ----------       ----------
Primary weighted average common and
  common equivalent shares outstanding ...      43,866,203       41,260,452       43,966,025       41,090,898
Dilutive effect of weighted average shares             532          373,614              531          574,634
                                                ----------       ----------       ----------       ----------
Fully diluted weighted average common and
  common equivalent shares outstanding ...      43,866,735       41,634,066       43,966,556       41,665,532
                                                ==========       ==========       ==========       ==========



                                       10