To add formulas to your project, add a new row into the Formulas table. Provide some name and copy a code of the formulas into the created row.
Class definition is not needed, add only variables and methods.
FormulaTester.dll is useful for debugging formulas in Visual Studio.