A modular system for ocean data assimilation has recently been developed. It has already been implemented in an unsophisticated way with a variety of models of the ocean and the coupled ocean-atmosphere. The system is currently being enhanced with modern information technology to facilitate the application of the system to models of coastal oceans, ocean basins, and the global ocean. One of the several ocean models that will interface with this "Inverse Ocean Modeling System" (IOM) is ADCIRC, a finite element circulation model for shelves, coasts, and estuaries. First, several aspects of the IOM are explained, with emphasis oil features that facilitate its implementation with a variety of models. Second. the unique challenges of interfacing, ADCIRC with the IOM are described, including the development of the time-discrete cost functional that depends on the primitive equation residuals (rather than the wave continuity residuals). Then the derivation of the forward and adjoint generalized wave continuity equations from the primitive Euler-Lagrange equations will be described by example.