Hi Jakub,
I think this is same problem previously cited:
For a point P, having orthometric height H (above MSL or Malin Head geoid), the geoid height relative to WGS84 is given by:
Nwgs84 = hwgs84 - H where hwgs84 is elipsoidal height relative to WGS84
and the geoid height or undulation relative to TM65 datum is:
Ntm65 = htm65 - H where htm65 is elipsoidal height relative to TM65 datum
so it follows that:
Ntm65 = Nwgs84 + htm65 - hwgs84
The geoid file OSGM02 is referenced to ETRS89 datum with geocentric spheroid GRS80 or WGS84 while Irish grid is referenced to TM65 datum with non geocentric spheroid Airy Modified 1849 with offset to WGS84 defined by 7 parameter similarity TOWGS84[482.5,-130.6,564.6,-1.042,-0.214,-0.631,8.15]
so you have to correct the OSGM02 geoid values by difference between ellipsoid heights for 2 spheroids as:
Ntm65_IrishGrid = Netrs89_osgm02 + htm65 - hetrs89_wgs84
PS which OSGM02 file are u using? Because the one I downloaded from geoids page coveres only Britain and not Ireland..