```\nfunction _calcQuoteAmountSellBase(\n        address baseToken,\n        uint256 baseAmount,\n        IWooracleV2.State memory state\n    ) private view returns (uint256 quoteAmount, uint256 newPrice) {\n        require(state.woFeasible, "WooPPV2: !ORACLE_FEASIBLE");\n\n        DecimalInfo memory decs = decimalInfo(baseToken);\n\n        // gamma = k * price * base_amount; and decimal 18\n        uint256 gamma;\n        {\n            uint256 notionalSwap = (baseAmount * state.price * decs.quoteDec) / decs.baseDec / decs.priceDec;\n            require(notionalSwap <= tokenInfos[baseToken].maxNotionalSwap, "WooPPV2: !maxNotionalValue");\n\n            gamma = (baseAmount * state.price * state.coeff) / decs.priceDec / decs.baseDec;\n            require(gamma <= tokenInfos[baseToken].maxGamma, "WooPPV2: !gamma");\n\n            // Formula: quoteAmount = baseAmount * oracle.price * (1 - oracle.k * baseAmount * oracle.price - oracle.spread)\n            quoteAmount =\n                (((baseAmount * state.price * decs.quoteDec) / decs.priceDec) *\n                    (uint256(1e18) - gamma - state.spread)) /\n                1e18 /\n                decs.baseDec;\n        }\n\n        // newPrice = oracle.price * (1 - k * oracle.price * baseAmount)\n        newPrice = ((uint256(1e18) - gamma) * state.price) / 1e18;\n    }\n```\n