```\n### BunniPrice.sol and BunniSupply.sol : \n    function _validateReserves( BunniKey memory key_,BunniLens lens_,uint16 twapMaxDeviationBps_,uint32 twapObservationWindow_) internal view \n        {\n        uint256 reservesTokenRatio = BunniHelper.getReservesRatio(key_, lens_);\n        uint256 twapTokenRatio = UniswapV3OracleHelper.getTWAPRatio(address(key_.pool),twapObservationWindow_);\n\n        // Revert if the relative deviation is greater than the maximum.\n        if (\n            // `isDeviatingWithBpsCheck()` will revert if `deviationBps` is invalid.\n            Deviation.isDeviatingWithBpsCheck(\n                reservesTokenRatio,\n                twapTokenRatio,\n                twapMaxDeviationBps_,\n                TWAP_MAX_DEVIATION_BASE\n            )\n        ) {\n            revert BunniPrice_PriceMismatch(address(key_.pool), twapTokenRatio, reservesTokenRatio);\n        }\n    }\n\n### BunniHelper.sol : \n    function getReservesRatio(BunniKey memory key_, BunniLens lens_) public view returns (uint256) {\n        IUniswapV3Pool pool = key_.pool;\n        uint8 token0Decimals = ERC20(pool.token0()).decimals();\n\n        (uint112 reserve0, uint112 reserve1) = lens_.getReserves(key_);\n        \n        //E compute fees and return values \n        (uint256 fee0, uint256 fee1) = lens_.getUncollectedFees(key_);\n        \n        //E calculates ratio of token1 in token0\n        return (reserve1 + fee1).mulDiv(10 ** token0Decimals, reserve0 + fee0);\n    }\n\n### UniswapV3OracleHelper.sol : \n    //E Returns the ratio of token1 to token0 in token1 decimals based on the TWAP\n        //E used in bophades/src/modules/PRICE/submodules/feeds/BunniPrice.sol, and SPPLY/submodules/BunniSupply.sol\n    function getTWAPRatio(\n        address pool_, \n        uint32 period_ //E period of the TWAP in seconds \n    ) public view returns (uint256) \n    {\n        //E return the time-weighted tick from period_ to now\n        int56 timeWeightedTick = getTimeWeightedTick(pool_, period_);\n\n        IUniswapV3Pool pool = IUniswapV3Pool(pool_);\n        ERC20 token0 = ERC20(pool.token0());\n        ERC20 token1 = ERC20(pool.token1());\n\n        // Quantity of token1 for 1 unit of token0 at the time-weighted tick\n        // Scale: token1 decimals\n        uint256 baseInQuote = OracleLibrary.getQuoteAtTick(\n            int24(timeWeightedTick),\n            uint128(10 ** token0.decimals()), // 1 unit of token0 => baseAmount\n            address(token0),\n            address(token1)\n        );\n        return baseInQuote;\n    }\n```\n