<?xml version="1.0" encoding="UTF-8"?>

<!--XBRL Document Created with the Workiva Platform-->
<!--Copyright 2026 Workiva-->
<!--r:019e2363-96e1-721a-bb2d-d3c158fa06a1,g:7e6776f2-2233-4188-b0a2-5a370a87bae0-->
<link:linkbase xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd">
  <link:arcroleRef arcroleURI="https://xbrl.org/2023/arcrole/summation-item" xlink:type="simple" xlink:href="https://www.xbrl.org/2023/calculation-1.1.xsd#summation-item"/>
  <link:roleRef roleURI="http://www.farmermac.com/role/CONSOLIDATEDBALANCESHEETSunaudited" xlink:type="simple" xlink:href="agm-20260630.xsd#CONSOLIDATEDBALANCESHEETSunaudited"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/CONSOLIDATEDBALANCESHEETSunaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_019e2363-9c60-77a6-a92f-255334b762df" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_StockholdersEquity"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PreferredStockValue_019e2363-9c60-71e0-b37b-de445be11f47" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PreferredStockValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019e2363-9c60-77a6-a92f-255334b762df" xlink:to="loc_us-gaap_PreferredStockValue_019e2363-9c60-71e0-b37b-de445be11f47" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommonStockValue_019e2363-9c60-7fbe-b66a-4fbafc1540b1" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CommonStockValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019e2363-9c60-77a6-a92f-255334b762df" xlink:to="loc_us-gaap_CommonStockValue_019e2363-9c60-7fbe-b66a-4fbafc1540b1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AdditionalPaidInCapital_019e2363-9c60-7c3a-8d2f-2c18c9ad78da" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AdditionalPaidInCapital"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019e2363-9c60-77a6-a92f-255334b762df" xlink:to="loc_us-gaap_AdditionalPaidInCapital_019e2363-9c60-7c3a-8d2f-2c18c9ad78da" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_019e2363-9c60-7802-9fa1-552cf8729f41" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019e2363-9c60-77a6-a92f-255334b762df" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_019e2363-9c60-7802-9fa1-552cf8729f41" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_019e2363-9c60-7c36-b947-e942a8247289" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_RetainedEarningsAccumulatedDeficit"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_019e2363-9c60-77a6-a92f-255334b762df" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_019e2363-9c60-7c36-b947-e942a8247289" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9c60-73d2-9d55-1e6ba2e4b70d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9c60-774f-b8fc-4387af0ddbc2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9c60-73d2-9d55-1e6ba2e4b70d" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9c60-774f-b8fc-4387af0ddbc2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossHeldInTrust_019e2363-9c60-7101-9c27-a4d849ee0bb2" xlink:href="agm-20260630.xsd#agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossHeldInTrust"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9c60-73d2-9d55-1e6ba2e4b70d" xlink:to="loc_agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossHeldInTrust_019e2363-9c60-7101-9c27-a4d849ee0bb2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_019e2363-9c60-7bd1-8d75-0e8aefc23c8d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9c60-73d2-9d55-1e6ba2e4b70d" xlink:to="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_019e2363-9c60-7bd1-8d75-0e8aefc23c8d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Investments_019e2363-9c60-795a-ac9f-13248ac60013" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Investments"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9c60-765b-8abb-a0367d154f6f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Investments_019e2363-9c60-795a-ac9f-13248ac60013" xlink:to="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9c60-765b-8abb-a0367d154f6f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9c60-760e-b60f-1252f2566b4d" xlink:href="agm-20260630.xsd#agm_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Investments_019e2363-9c60-795a-ac9f-13248ac60013" xlink:to="loc_agm_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9c60-760e-b60f-1252f2566b4d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherInvestments_019e2363-9c60-7dac-8170-9656d6ecc62d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherInvestments"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Investments_019e2363-9c60-795a-ac9f-13248ac60013" xlink:to="loc_us-gaap_OtherInvestments_019e2363-9c60-7dac-8170-9656d6ecc62d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_019e2363-9c60-7890-9d1e-475bdb0c6e02" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Liabilities"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtNetOfHedgingAdjustments_019e2363-9c60-72a7-bad8-ccf69412811e" xlink:href="agm-20260630.xsd#agm_LongTermDebtNetOfHedgingAdjustments"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019e2363-9c60-7890-9d1e-475bdb0c6e02" xlink:to="loc_agm_LongTermDebtNetOfHedgingAdjustments_019e2363-9c60-72a7-bad8-ccf69412811e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LiabilitiesHeldInTrust_019e2363-9c60-7cd9-af38-7849b0498ef2" xlink:href="agm-20260630.xsd#agm_LiabilitiesHeldInTrust"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019e2363-9c60-7890-9d1e-475bdb0c6e02" xlink:to="loc_agm_LiabilitiesHeldInTrust_019e2363-9c60-7cd9-af38-7849b0498ef2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilities_019e2363-9c60-7f07-a908-74eec7bd5536" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilities"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019e2363-9c60-7890-9d1e-475bdb0c6e02" xlink:to="loc_us-gaap_DerivativeLiabilities_019e2363-9c60-7f07-a908-74eec7bd5536" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestPayableCurrentAndNoncurrent_019e2363-9c60-7bd9-aabe-7e22128e91ba" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestPayableCurrentAndNoncurrent"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019e2363-9c60-7890-9d1e-475bdb0c6e02" xlink:to="loc_us-gaap_InterestPayableCurrentAndNoncurrent_019e2363-9c60-7bd9-aabe-7e22128e91ba" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GuarantyLiabilities_019e2363-9c60-7f6e-9e7c-522df12b754e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GuarantyLiabilities"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019e2363-9c60-7890-9d1e-475bdb0c6e02" xlink:to="loc_us-gaap_GuarantyLiabilities_019e2363-9c60-7f6e-9e7c-522df12b754e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccountsPayableAndOtherAccruedLiabilities_019e2363-9c60-71ef-98f0-4f344050b024" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccountsPayableAndOtherAccruedLiabilities"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_019e2363-9c60-7890-9d1e-475bdb0c6e02" xlink:to="loc_us-gaap_AccountsPayableAndOtherAccruedLiabilities_019e2363-9c60-71ef-98f0-4f344050b024" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Assets"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9c60-7960-97e7-729c823b374f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9c60-7960-97e7-729c823b374f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssets_019e2363-9c60-7859-9bac-4c3037186c9b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssets"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_DerivativeAssets_019e2363-9c60-7859-9bac-4c3037186c9b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestReceivable_019e2363-9c60-73af-bf8d-337be25ee58c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestReceivable"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_InterestReceivable_019e2363-9c60-73af-bf8d-337be25ee58c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GuarantyAssets_019e2363-9c60-7015-95ae-2d0366a8f8e8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GuarantyAssets"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_GuarantyAssets_019e2363-9c60-7015-95ae-2d0366a8f8e8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxAssetsNet_019e2363-9c60-729b-a93b-ef1bf4088380" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DeferredIncomeTaxAssetsNet"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_DeferredIncomeTaxAssetsNet_019e2363-9c60-729b-a93b-ef1bf4088380" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PrepaidExpenseAndOtherAssets_019e2363-9c60-71f6-880d-22ea3dcf370a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PrepaidExpenseAndOtherAssets"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_PrepaidExpenseAndOtherAssets_019e2363-9c60-71f6-880d-22ea3dcf370a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_019e2363-9c60-7213-adf5-9ba214931c4a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalents_019e2363-9c60-7213-adf5-9ba214931c4a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Investments_019e2363-9c60-7b63-aa36-f62cfe8b7a43" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Investments"/>
    <link:calculationArc order="8" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9c60-7158-8be1-10c50f1488ed" xlink:to="loc_us-gaap_Investments_019e2363-9c60-7b63-aa36-f62cfe8b7a43" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_019e2363-9c60-7de6-94af-b01bf59e05e8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LiabilitiesAndStockholdersEquity"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_019e2363-9c60-7e7e-bfc0-36bee38eddea" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Liabilities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_019e2363-9c60-7de6-94af-b01bf59e05e8" xlink:to="loc_us-gaap_Liabilities_019e2363-9c60-7e7e-bfc0-36bee38eddea" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_019e2363-9c60-7930-9a89-435ea1ccf2ae" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_StockholdersEquity"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_019e2363-9c60-7de6-94af-b01bf59e05e8" xlink:to="loc_us-gaap_StockholdersEquity_019e2363-9c60-7930-9a89-435ea1ccf2ae" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommitmentsAndContingencies_019e2363-9c60-745b-8bc8-f6906069b09a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CommitmentsAndContingencies"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_019e2363-9c60-7de6-94af-b01bf59e05e8" xlink:to="loc_us-gaap_CommitmentsAndContingencies_019e2363-9c60-745b-8bc8-f6906069b09a" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/CONSOLIDATEDSTATEMENTSOFOPERATIONSunaudited" xlink:type="simple" xlink:href="agm-20260630.xsd#CONSOLIDATEDSTATEMENTSOFOPERATIONSunaudited"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/CONSOLIDATEDSTATEMENTSOFOPERATIONSunaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_019e2363-9d29-71f2-a125-7e0c6276817a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019e2363-9d29-75ef-9edb-eddbee1df5d4" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_019e2363-9d29-71f2-a125-7e0c6276817a" xlink:to="loc_us-gaap_NetIncomeLoss_019e2363-9d29-75ef-9edb-eddbee1df5d4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PreferredStockDividendsIncomeStatementImpact_019e2363-9d29-7edc-bd77-7a15f1de738d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PreferredStockDividendsIncomeStatementImpact"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_019e2363-9d29-71f2-a125-7e0c6276817a" xlink:to="loc_us-gaap_PreferredStockDividendsIncomeStatementImpact_019e2363-9d29-7edc-bd77-7a15f1de738d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019e2363-9d29-7850-8540-6fc26f569eef" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019e2363-9d29-7a30-90e5-b7a6cc8f88bf" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019e2363-9d29-7850-8540-6fc26f569eef" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019e2363-9d29-7a30-90e5-b7a6cc8f88bf" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_019e2363-9d29-7961-8ac5-f77525736e69" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncomeTaxExpenseBenefit"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019e2363-9d29-7850-8540-6fc26f569eef" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_019e2363-9d29-7961-8ac5-f77525736e69" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_019e2363-9d29-7e7d-8813-119d76e3c916" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseNet_019e2363-9d29-77e6-b17f-7812d6b89120" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestIncomeExpenseNet"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_019e2363-9d29-7e7d-8813-119d76e3c916" xlink:to="loc_us-gaap_InterestIncomeExpenseNet_019e2363-9d29-77e6-b17f-7812d6b89120" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProvisionForLoanLeaseAndOtherLosses_019e2363-9d29-7585-a781-0701387f8bec" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProvisionForLoanLeaseAndOtherLosses"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_019e2363-9d29-7e7d-8813-119d76e3c916" xlink:to="loc_us-gaap_ProvisionForLoanLeaseAndOtherLosses_019e2363-9d29-7585-a781-0701387f8bec" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseNet_019e2363-9d29-7837-94eb-91d60b628920" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestIncomeExpenseNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndDividendIncomeOperating_019e2363-9d29-7f15-b0a5-29f3cdd8b686" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestAndDividendIncomeOperating"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseNet_019e2363-9d29-7837-94eb-91d60b628920" xlink:to="loc_us-gaap_InterestAndDividendIncomeOperating_019e2363-9d29-7f15-b0a5-29f3cdd8b686" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseOperating_019e2363-9d29-7f5b-8e34-8ba11da814bc" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestExpenseOperating"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseNet_019e2363-9d29-7837-94eb-91d60b628920" xlink:to="loc_us-gaap_InterestExpenseOperating_019e2363-9d29-7f5b-8e34-8ba11da814bc" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019e2363-9d29-7e61-a52e-7b6487fef74b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_019e2363-9d29-7f6f-9f7f-af3a2d4fcc24" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019e2363-9d29-7e61-a52e-7b6487fef74b" xlink:to="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_019e2363-9d29-7f6f-9f7f-af3a2d4fcc24" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NoninterestIncome_019e2363-9d29-7a3a-ba66-b864d5ada416" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NoninterestIncome"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019e2363-9d29-7e61-a52e-7b6487fef74b" xlink:to="loc_us-gaap_NoninterestIncome_019e2363-9d29-7a3a-ba66-b864d5ada416" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses_019e2363-9d29-7e2b-a691-d01ebe204173" xlink:href="agm-20260630.xsd#agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_019e2363-9d29-7e61-a52e-7b6487fef74b" xlink:to="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses_019e2363-9d29-7e2b-a691-d01ebe204173" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NoninterestIncome_019e2363-9d29-7a96-bf19-230b39d9d3df" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NoninterestIncome"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InvestmentBankingAdvisoryBrokerageAndUnderwritingFeesAndCommissions_019e2363-9d29-78d6-8dc1-5aa72de75e6d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InvestmentBankingAdvisoryBrokerageAndUnderwritingFeesAndCommissions"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestIncome_019e2363-9d29-7a96-bf19-230b39d9d3df" xlink:to="loc_us-gaap_InvestmentBankingAdvisoryBrokerageAndUnderwritingFeesAndCommissions_019e2363-9d29-78d6-8dc1-5aa72de75e6d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnDerivativeInstrumentsNetPretax_019e2363-9d29-7407-b292-1fb05cb25e9e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GainLossOnDerivativeInstrumentsNetPretax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestIncome_019e2363-9d29-7a96-bf19-230b39d9d3df" xlink:to="loc_us-gaap_GainLossOnDerivativeInstrumentsNetPretax_019e2363-9d29-7407-b292-1fb05cb25e9e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NoninterestIncomeOtherOperatingIncome_019e642f-4440-7873-837e-ddcd182fba0f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NoninterestIncomeOtherOperatingIncome"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestIncome_019e2363-9d29-7a96-bf19-230b39d9d3df" xlink:to="loc_us-gaap_NoninterestIncomeOtherOperatingIncome_019e642f-4440-7873-837e-ddcd182fba0f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses_019e2363-9d29-7e41-8dfe-ed22096cae9f" xlink:href="agm-20260630.xsd#agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LaborAndRelatedExpense_019e2363-9d29-72b2-b70d-f10f79a8f910" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LaborAndRelatedExpense"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses_019e2363-9d29-7e41-8dfe-ed22096cae9f" xlink:to="loc_us-gaap_LaborAndRelatedExpense_019e2363-9d29-72b2-b70d-f10f79a8f910" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GeneralAndAdministrativeExpense_019e2363-9d29-7860-ae4e-2a4507c74404" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GeneralAndAdministrativeExpense"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses_019e2363-9d29-7e41-8dfe-ed22096cae9f" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpense_019e2363-9d29-7860-ae4e-2a4507c74404" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_RegulatoryFees_019e2363-9d29-7074-bfe4-8826981ca7a1" xlink:href="agm-20260630.xsd#agm_RegulatoryFees"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLosses_019e2363-9d29-7e41-8dfe-ed22096cae9f" xlink:to="loc_agm_RegulatoryFees_019e2363-9d29-7074-bfe4-8826981ca7a1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndDividendIncomeOperating_019e2363-9d29-7409-9c85-6595437c6154" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestAndDividendIncomeOperating"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndFeeIncomeLoansAndLeases_019e2363-9d29-77f3-844e-4181e3891df8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestAndFeeIncomeLoansAndLeases"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InterestAndDividendIncomeOperating_019e2363-9d29-7409-9c85-6595437c6154" xlink:to="loc_us-gaap_InterestAndFeeIncomeLoansAndLeases_019e2363-9d29-77f3-844e-4181e3891df8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndDividendIncomeSecurities_019e2363-9d29-76c4-8950-18b714169afc" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestAndDividendIncomeSecurities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_InterestAndDividendIncomeOperating_019e2363-9d29-7409-9c85-6595437c6154" xlink:to="loc_us-gaap_InterestAndDividendIncomeSecurities_019e2363-9d29-76c4-8950-18b714169afc" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOMEunaudited" xlink:type="simple" xlink:href="agm-20260630.xsd#CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOMEunaudited"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/CONSOLIDATEDSTATEMENTSOFCOMPREHENSIVEINCOMEunaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-7074-ba15-5605e08b1432" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_OtherComprehensiveIncomeLossHeldToMaturitySecuritiesBeforeTax_019e2363-9d29-797b-a547-3617547954d9" xlink:href="agm-20260630.xsd#agm_OtherComprehensiveIncomeLossHeldToMaturitySecuritiesBeforeTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-7074-ba15-5605e08b1432" xlink:to="loc_agm_OtherComprehensiveIncomeLossHeldToMaturitySecuritiesBeforeTax_019e2363-9d29-797b-a547-3617547954d9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossAvailableForSaleSecuritiesAdjustmentBeforeTax_019e2363-9d29-70f7-b5ba-16afda862f0b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossAvailableForSaleSecuritiesAdjustmentBeforeTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-7074-ba15-5605e08b1432" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossAvailableForSaleSecuritiesAdjustmentBeforeTax_019e2363-9d29-70f7-b5ba-16afda862f0b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax_019e2363-9d29-70b5-b152-3b1830fa7975" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-7074-ba15-5605e08b1432" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossBeforeReclassificationAfterTax_019e2363-9d29-70b5-b152-3b1830fa7975" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-70fe-aaa3-1a0fa993db50" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-7539-99d5-f6afa80c9e20" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-70fe-aaa3-1a0fa993db50" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-7539-99d5-f6afa80c9e20" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossTaxPortionAttributableToParent1_019e2363-9d29-7e20-b569-c3f4b1a89fda" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossTaxPortionAttributableToParent1"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-70fe-aaa3-1a0fa993db50" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossTaxPortionAttributableToParent1_019e2363-9d29-7e20-b569-c3f4b1a89fda" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ComprehensiveIncomeNetOfTax_019e2363-9d29-7ab9-be7e-2373ddea22b9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ComprehensiveIncomeNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019e2363-9d29-712a-b414-d5f0985a3788" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_019e2363-9d29-7ab9-be7e-2373ddea22b9" xlink:to="loc_us-gaap_NetIncomeLoss_019e2363-9d29-712a-b414-d5f0985a3788" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-7f32-9f3f-de4c121fcb3d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_019e2363-9d29-7ab9-be7e-2373ddea22b9" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-7f32-9f3f-de4c121fcb3d" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/CONSOLIDATEDSTATEMENTSOFCASHFLOWSunaudited" xlink:type="simple" xlink:href="agm-20260630.xsd#CONSOLIDATEDSTATEMENTSOFCASHFLOWSunaudited"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/CONSOLIDATEDSTATEMENTSOFCASHFLOWSunaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019e2363-9d29-7368-abb1-f9371462c838" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-710e-b44a-1442f0b667f5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019e2363-9d29-7368-abb1-f9371462c838" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-710e-b44a-1442f0b667f5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-777b-b344-a27f04d479ad" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019e2363-9d29-7368-abb1-f9371462c838" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-777b-b344-a27f04d479ad" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-71b4-bf9f-7b7d4fd6a54e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseIncludingExchangeRateEffect_019e2363-9d29-7368-abb1-f9371462c838" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-71b4-bf9f-7b7d4fd6a54e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019e2363-9d29-7639-87b3-64f503a4a619" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_NetIncomeLoss_019e2363-9d29-7639-87b3-64f503a4a619" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccretionAmortizationOfDiscountsAndPremiumsInvestments_019e2363-9d29-7b54-b99a-e56f187ca391" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AccretionAmortizationOfDiscountsAndPremiumsInvestments"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_AccretionAmortizationOfDiscountsAndPremiumsInvestments_019e2363-9d29-7b54-b99a-e56f187ca391" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AmortizationOfFinancingCostsAndDiscounts_019e2363-9d29-738a-a13d-a9c2dfd38900" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AmortizationOfFinancingCostsAndDiscounts"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_AmortizationOfFinancingCostsAndDiscounts_019e2363-9d29-738a-a13d-a9c2dfd38900" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_NetChangeInFairValueTradingSecuritiesHedgedAssetsFinancialDerivativesAndLoansHeldForSale_019e2363-9d29-7f83-8d6c-b6929bbe2a83" xlink:href="agm-20260630.xsd#agm_NetChangeInFairValueTradingSecuritiesHedgedAssetsFinancialDerivativesAndLoansHeldForSale"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_agm_NetChangeInFairValueTradingSecuritiesHedgedAssetsFinancialDerivativesAndLoansHeldForSale_019e2363-9d29-7f83-8d6c-b6929bbe2a83" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_ProvisionForLoanLeaseAndOtherLossesNoncash_019e2363-9d29-7c68-9e89-31754fe40a2c" xlink:href="agm-20260630.xsd#agm_ProvisionForLoanLeaseAndOtherLossesNoncash"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_agm_ProvisionForLoanLeaseAndOtherLossesNoncash_019e2363-9d29-7c68-9e89-31754fe40a2c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ShareBasedCompensation_019e2363-9d29-76e5-806e-dc1c6c6c55d9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ShareBasedCompensation"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_ShareBasedCompensation_019e2363-9d29-76e5-806e-dc1c6c6c55d9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToPurchaseLoansHeldForSale_019e2363-9d29-7525-aded-d3ff30aae549" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToPurchaseLoansHeldForSale"/>
    <link:calculationArc order="7" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_PaymentsToPurchaseLoansHeldForSale_019e2363-9d29-7525-aded-d3ff30aae549" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromCollectionOfLoansHeldForSale_019e2363-9d29-7b43-8b53-d4185d30ae97" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromCollectionOfLoansHeldForSale"/>
    <link:calculationArc order="8" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_ProceedsFromCollectionOfLoansHeldForSale_019e2363-9d29-7b43-8b53-d4185d30ae97" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_PaymentsToAcquireTaxCredits_019e2363-9d29-7023-9b62-82cb3a12dbf6" xlink:href="agm-20260630.xsd#agm_PaymentsToAcquireTaxCredits"/>
    <link:calculationArc order="9" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_agm_PaymentsToAcquireTaxCredits_019e2363-9d29-7023-9b62-82cb3a12dbf6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNoncashIncomeExpense_019e2363-9d29-713a-99f4-0500260553a3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherNoncashIncomeExpense"/>
    <link:calculationArc order="10" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_OtherNoncashIncomeExpense_019e2363-9d29-713a-99f4-0500260553a3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccruedInterestReceivableNet_019e2363-9d29-7f9b-9a61-0a8077e241ae" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInAccruedInterestReceivableNet"/>
    <link:calculationArc order="11" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedInterestReceivableNet_019e2363-9d29-7f9b-9a61-0a8077e241ae" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInOtherReceivables_019e2363-9d29-73b4-a558-e74224a9f1a2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInOtherReceivables"/>
    <link:calculationArc order="12" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_IncreaseDecreaseInOtherReceivables_019e2363-9d29-73b4-a558-e74224a9f1a2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInOtherOperatingAssets_019e2363-9d29-7983-a0ea-5fd440d12fc5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInOtherOperatingAssets"/>
    <link:calculationArc order="13" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_IncreaseDecreaseInOtherOperatingAssets_019e2363-9d29-7983-a0ea-5fd440d12fc5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInAccruedLiabilities_019e2363-9d29-730c-b7a0-f06ed3bd1693" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInAccruedLiabilities"/>
    <link:calculationArc order="14" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_IncreaseDecreaseInAccruedLiabilities_019e2363-9d29-730c-b7a0-f06ed3bd1693" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInContractWithCustomerLiability_019e2363-9d29-7bf2-bc0a-57bfb5884ff9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInContractWithCustomerLiability"/>
    <link:calculationArc order="15" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_IncreaseDecreaseInContractWithCustomerLiability_019e2363-9d29-7bf2-bc0a-57bfb5884ff9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncreaseDecreaseInOtherOperatingLiabilities_019e643c-3d57-7678-9fc2-6977ea4c9705" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncreaseDecreaseInOtherOperatingLiabilities"/>
    <link:calculationArc order="16" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_019e2363-9d29-7805-861c-2b6b31903ae8" xlink:to="loc_us-gaap_IncreaseDecreaseInOtherOperatingLiabilities_019e643c-3d57-7678-9fc2-6977ea4c9705" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromNotesPayable_019e2363-9d29-751f-9e96-febb7e549f2e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromNotesPayable"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_ProceedsFromNotesPayable_019e2363-9d29-751f-9e96-febb7e549f2e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfTrustPreferredSecurities_019e2363-9d29-7dd5-863a-0c286ac4cd1e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromIssuanceOfTrustPreferredSecurities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfTrustPreferredSecurities_019e2363-9d29-7dd5-863a-0c286ac4cd1e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RepaymentsOfNotesPayable_019e2363-9d29-7c13-8461-fede98ff3346" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_RepaymentsOfNotesPayable"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_RepaymentsOfNotesPayable_019e2363-9d29-7c13-8461-fede98ff3346" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_PaymentsToThirdPartiesOnDebtSecuritiesOfConsolidatedTrusts_019e2363-9d29-7523-8e0b-5f1a16429375" xlink:href="agm-20260630.xsd#agm_PaymentsToThirdPartiesOnDebtSecuritiesOfConsolidatedTrusts"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_agm_PaymentsToThirdPartiesOnDebtSecuritiesOfConsolidatedTrusts_019e2363-9d29-7523-8e0b-5f1a16429375" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_019e2363-9d29-7caa-b453-8cfa8d89f657" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsForRepurchaseOfCommonStock"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_PaymentsForRepurchaseOfCommonStock_019e2363-9d29-7caa-b453-8cfa8d89f657" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfCommonStock_019e2363-9d29-750c-b046-280982eaf243" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromIssuanceOfCommonStock"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfCommonStock_019e2363-9d29-750c-b046-280982eaf243" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfPreferredStockAndPreferenceStock_019e2363-9d29-7ce4-83d5-8226ae320c3a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromIssuanceOfPreferredStockAndPreferenceStock"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfPreferredStockAndPreferenceStock_019e2363-9d29-7ce4-83d5-8226ae320c3a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation_019e643e-ec3b-7b18-ae29-95922244555e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation"/>
    <link:calculationArc order="8" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_PaymentsRelatedToTaxWithholdingForShareBasedCompensation_019e643e-ec3b-7b18-ae29-95922244555e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsOfOrdinaryDividends_019e643e-ec3b-75e3-85c5-78a4fd0b6105" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsOfOrdinaryDividends"/>
    <link:calculationArc order="9" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_019e2363-9d29-721d-b7fa-3251bd834bec" xlink:to="loc_us-gaap_PaymentsOfOrdinaryDividends_019e643e-ec3b-75e3-85c5-78a4fd0b6105" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireAvailableForSaleSecuritiesDebt_019e2363-9d29-7f41-bcdb-67a66762a49e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToAcquireAvailableForSaleSecuritiesDebt"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_PaymentsToAcquireAvailableForSaleSecuritiesDebt_019e2363-9d29-7f41-bcdb-67a66762a49e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireHeldToMaturitySecurities_019e2363-9d29-7c03-b370-fec8dbdaf3a8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToAcquireHeldToMaturitySecurities"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_PaymentsToAcquireHeldToMaturitySecurities_019e2363-9d29-7c03-b370-fec8dbdaf3a8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireOtherInvestments_019e2363-9d29-7e26-92f2-5f4bb2a3470a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToAcquireOtherInvestments"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_PaymentsToAcquireOtherInvestments_019e2363-9d29-7e26-92f2-5f4bb2a3470a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireLoansHeldForInvestment_019e2363-9d29-7442-8fa3-c46ee6c1eab8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToAcquireLoansHeldForInvestment"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_PaymentsToAcquireLoansHeldForInvestment_019e2363-9d29-7442-8fa3-c46ee6c1eab8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireOtherLoansAndLeasesHeldForInvestment_019e2363-9d29-73ee-87c6-82b8baa35dfd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_PaymentsToAcquireOtherLoansAndLeasesHeldForInvestment"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_PaymentsToAcquireOtherLoansAndLeasesHeldForInvestment_019e2363-9d29-73ee-87c6-82b8baa35dfd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleAndMaturityOfAvailableForSaleSecurities_019e2363-9d29-71d8-8e5d-5bb3e37d0ed8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromSaleAndMaturityOfAvailableForSaleSecurities"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_ProceedsFromSaleAndMaturityOfAvailableForSaleSecurities_019e2363-9d29-71d8-8e5d-5bb3e37d0ed8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleAndMaturityOfHeldToMaturitySecurities_019e2363-9d29-7018-95a8-88c82c5c225b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromSaleAndMaturityOfHeldToMaturitySecurities"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_ProceedsFromSaleAndMaturityOfHeldToMaturitySecurities_019e2363-9d29-7018-95a8-88c82c5c225b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromPrincipalRepaymentsOnLoansAndLeasesHeldForInvestment_019e2363-9d29-79e1-91af-027836084b76" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromPrincipalRepaymentsOnLoansAndLeasesHeldForInvestment"/>
    <link:calculationArc order="8" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_ProceedsFromPrincipalRepaymentsOnLoansAndLeasesHeldForInvestment_019e2363-9d29-79e1-91af-027836084b76" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleOfOtherRealEstate_019e643f-0959-7f66-993f-2989c99f489f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromSaleOfOtherRealEstate"/>
    <link:calculationArc order="9" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_ProceedsFromSaleOfOtherRealEstate_019e643f-0959-7f66-993f-2989c99f489f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleOfLoansHeldForInvestment_019e643f-0959-7755-b940-2ff74d71d308" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ProceedsFromSaleOfLoansHeldForInvestment"/>
    <link:calculationArc order="10" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_019e2363-9d29-781c-8ad0-1470ae019477" xlink:to="loc_us-gaap_ProceedsFromSaleOfLoansHeldForInvestment_019e643f-0959-7755-b940-2ff74d71d308" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofEarningsPerCommonShareDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofEarningsPerCommonShareDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofEarningsPerCommonShareDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EarningsPerShareDiluted_019e2363-9d29-7224-842a-f5d47af5f807" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_EarningsPerShareDiluted"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_EarningsPerShareBasic_019e2363-9d29-7267-ba1b-db326b6bc42f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_EarningsPerShareBasic"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_EarningsPerShareDiluted_019e2363-9d29-7224-842a-f5d47af5f807" xlink:to="loc_us-gaap_EarningsPerShareBasic_019e2363-9d29-7267-ba1b-db326b6bc42f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_EarningsPerShareOnIncrementalCommonSharesAttributableToShareBasedPaymentArrangements_019e2363-9d29-7309-8240-66b87bed4d90" xlink:href="agm-20260630.xsd#agm_EarningsPerShareOnIncrementalCommonSharesAttributableToShareBasedPaymentArrangements"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_EarningsPerShareDiluted_019e2363-9d29-7224-842a-f5d47af5f807" xlink:to="loc_agm_EarningsPerShareOnIncrementalCommonSharesAttributableToShareBasedPaymentArrangements_019e2363-9d29-7309-8240-66b87bed4d90" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersDiluted_019e2363-9d29-7f27-917b-d65344c44741" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLossAvailableToCommonStockholdersDiluted"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_019e2363-9d29-7021-98c0-82d92ef2b643" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersDiluted_019e2363-9d29-7f27-917b-d65344c44741" xlink:to="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_019e2363-9d29-7021-98c0-82d92ef2b643" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_019e2363-9d29-7012-b700-0aea02700516" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_019e2363-9d29-7759-8e2b-38aec700e3c6" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_WeightedAverageNumberOfSharesOutstandingBasic"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_019e2363-9d29-7012-b700-0aea02700516" xlink:to="loc_us-gaap_WeightedAverageNumberOfSharesOutstandingBasic_019e2363-9d29-7759-8e2b-38aec700e3c6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_019e2363-9d29-7e36-8830-17f14ee0c1cb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_WeightedAverageNumberOfDilutedSharesOutstanding_019e2363-9d29-7012-b700-0aea02700516" xlink:to="loc_us-gaap_IncrementalCommonSharesAttributableToShareBasedPaymentArrangements_019e2363-9d29-7e36-8830-17f14ee0c1cb" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofAccumulatedOtherComprehensiveIncomeNetofTaxDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofAccumulatedOtherComprehensiveIncomeNetofTaxDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofAccumulatedOtherComprehensiveIncomeNetofTaxDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-7e2a-bcc0-4d684c8fc99f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OciBeforeReclassificationsNetOfTaxAttributableToParent_019e2363-9d29-7e1f-8b29-1785b0014863" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OciBeforeReclassificationsNetOfTaxAttributableToParent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-7e2a-bcc0-4d684c8fc99f" xlink:to="loc_us-gaap_OciBeforeReclassificationsNetOfTaxAttributableToParent_019e2363-9d29-7e1f-8b29-1785b0014863" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ReclassificationFromAociCurrentPeriodNetOfTaxAttributableToParent_019e2363-9d29-7c7e-8ed9-11cde9ef0ee6" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ReclassificationFromAociCurrentPeriodNetOfTaxAttributableToParent"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTaxPortionAttributableToParent_019e2363-9d29-7e2a-bcc0-4d684c8fc99f" xlink:to="loc_us-gaap_ReclassificationFromAociCurrentPeriodNetOfTaxAttributableToParent_019e2363-9d29-7c7e-8ed9-11cde9ef0ee6" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofReclassificationoutofAccumulatedOtherComprehensiveIncomeDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofReclassificationoutofAccumulatedOtherComprehensiveIncomeDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/SUMMARYOFSIGNIFICANTACCOUNTINGPOLICIESScheduleofReclassificationoutofAccumulatedOtherComprehensiveIncomeDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OciBeforeReclassificationsNetOfTaxAttributableToParent_019e2363-9d29-7207-837e-599e9c6ca161" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OciBeforeReclassificationsNetOfTaxAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OciBeforeReclassificationsBeforeTaxAttributableToParent_019e2363-9d29-7de9-bf6f-d2ae5b146bd9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OciBeforeReclassificationsBeforeTaxAttributableToParent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OciBeforeReclassificationsNetOfTaxAttributableToParent_019e2363-9d29-7207-837e-599e9c6ca161" xlink:to="loc_us-gaap_OciBeforeReclassificationsBeforeTaxAttributableToParent_019e2363-9d29-7de9-bf6f-d2ae5b146bd9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsTax_019e2363-9d29-75ec-ac07-cca86e0363d1" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OciBeforeReclassificationsNetOfTaxAttributableToParent_019e2363-9d29-7207-837e-599e9c6ca161" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsTax_019e2363-9d29-75ec-ac07-cca86e0363d1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossTaxPortionAttributableToParent1_019e2363-9d29-783f-a22f-75ca9ad721bf" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossTaxPortionAttributableToParent1"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsTax_019e2363-9d29-758f-9a60-97be2227df62" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossTaxPortionAttributableToParent1_019e2363-9d29-783f-a22f-75ca9ad721bf" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossBeforeReclassificationsTax_019e2363-9d29-758f-9a60-97be2227df62" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ReclassificationFromAociCurrentPeriodTax_019e2363-9d29-7d8a-b50a-b955906cad17" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ReclassificationFromAociCurrentPeriodTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossTaxPortionAttributableToParent1_019e2363-9d29-783f-a22f-75ca9ad721bf" xlink:to="loc_us-gaap_ReclassificationFromAociCurrentPeriodTax_019e2363-9d29-7d8a-b50a-b955906cad17" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ReclassificationFromAociCurrentPeriodNetOfTaxAttributableToParent_019e2363-9d29-7098-abab-67420eaa6af1" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ReclassificationFromAociCurrentPeriodNetOfTaxAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ReclassificationFromAociCurrentPeriodBeforeTaxAttributableToParent_019e2363-9d29-726a-b548-1d9db84e3113" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ReclassificationFromAociCurrentPeriodBeforeTaxAttributableToParent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ReclassificationFromAociCurrentPeriodNetOfTaxAttributableToParent_019e2363-9d29-7098-abab-67420eaa6af1" xlink:to="loc_us-gaap_ReclassificationFromAociCurrentPeriodBeforeTaxAttributableToParent_019e2363-9d29-726a-b548-1d9db84e3113" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ReclassificationFromAociCurrentPeriodTax_019e2363-9d29-7603-ad3c-3eab5a7a0113" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ReclassificationFromAociCurrentPeriodTax"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_ReclassificationFromAociCurrentPeriodNetOfTaxAttributableToParent_019e2363-9d29-7098-abab-67420eaa6af1" xlink:to="loc_us-gaap_ReclassificationFromAociCurrentPeriodTax_019e2363-9d29-7603-ad3c-3eab5a7a0113" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-72e2-a2af-cb76ebefe0bd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OciBeforeReclassificationsBeforeTaxAttributableToParent_019e2363-9d29-7724-b6a2-5be53047047f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OciBeforeReclassificationsBeforeTaxAttributableToParent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-72e2-a2af-cb76ebefe0bd" xlink:to="loc_us-gaap_OciBeforeReclassificationsBeforeTaxAttributableToParent_019e2363-9d29-7724-b6a2-5be53047047f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ReclassificationFromAociCurrentPeriodBeforeTaxAttributableToParent_019e2363-9d29-75d5-b559-cbcc562bee52" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ReclassificationFromAociCurrentPeriodBeforeTaxAttributableToParent"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossBeforeTaxPortionAttributableToParent_019e2363-9d29-72e2-a2af-cb76ebefe0bd" xlink:to="loc_us-gaap_ReclassificationFromAociCurrentPeriodBeforeTaxAttributableToParent_019e2363-9d29-75d5-b559-cbcc562bee52" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/INVESTMENTSECURITIESScheduleofAFSSecuritiesMaturitiesDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#INVESTMENTSECURITIESScheduleofAFSSecuritiesMaturitiesDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/INVESTMENTSECURITIESScheduleofAFSSecuritiesMaturitiesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-7886-b8c2-b4c7d6806f7c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveThroughTenYearsAmortizedCost_019e2363-9d2a-7031-b1a4-e9adb67c6aed" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveThroughTenYearsAmortizedCost"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-7886-b8c2-b4c7d6806f7c" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveThroughTenYearsAmortizedCost_019e2363-9d2a-7031-b1a4-e9adb67c6aed" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterOneThroughFiveYearsAmortizedCost_019e2363-9d2a-7dcc-bb50-86352b7a70f3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterOneThroughFiveYearsAmortizedCost"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-7886-b8c2-b4c7d6806f7c" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterOneThroughFiveYearsAmortizedCost_019e2363-9d2a-7dcc-bb50-86352b7a70f3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterTenYearsAmortizedCost_019e2363-9d2a-7036-9595-89ab140ecb5d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterTenYearsAmortizedCost"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-7886-b8c2-b4c7d6806f7c" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterTenYearsAmortizedCost_019e2363-9d2a-7036-9595-89ab140ecb5d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearAmortizedCost_019e2363-9d2a-7900-944b-2f3b477ae431" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearAmortizedCost"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-7886-b8c2-b4c7d6806f7c" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearAmortizedCost_019e2363-9d2a-7900-944b-2f3b477ae431" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9d2a-72f9-ab51-dc89eb731691" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterTenYearsFairValue_019e2363-9d2a-7014-860c-a271639a8f3f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterTenYearsFairValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9d2a-72f9-ab51-dc89eb731691" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterTenYearsFairValue_019e2363-9d2a-7014-860c-a271639a8f3f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue_019e2363-9d2a-754c-8380-1abdcdd0a0fd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9d2a-72f9-ab51-dc89eb731691" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesWithinOneYearFairValue_019e2363-9d2a-754c-8380-1abdcdd0a0fd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveThroughTenYearsFairValue_019e2363-9d2a-7aeb-be76-3e9f2c365a6a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveThroughTenYearsFairValue"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9d2a-72f9-ab51-dc89eb731691" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterFiveThroughTenYearsFairValue_019e2363-9d2a-7aeb-be76-3e9f2c365a6a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterOneThroughFiveYearsFairValue_019e2363-9d2a-792b-8d9e-71303ba07dfb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterOneThroughFiveYearsFairValue"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9d2a-72f9-ab51-dc89eb731691" xlink:to="loc_us-gaap_AvailableForSaleSecuritiesDebtMaturitiesAfterOneThroughFiveYearsFairValue_019e2363-9d2a-792b-8d9e-71303ba07dfb" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/INVESTMENTSECURITIESScheduleofHTMSecuritiesMaturitiesDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#INVESTMENTSECURITIESScheduleofHTMSecuritiesMaturitiesDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/INVESTMENTSECURITIESScheduleofHTMSecuritiesMaturitiesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDate_019e2363-9d2a-71f9-9519-bbad24d597a8" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDate"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateYearOne_019e2363-9d2a-7556-b82e-691b86bce773" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateYearOne"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDate_019e2363-9d2a-71f9-9519-bbad24d597a8" xlink:to="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateYearOne_019e2363-9d2a-7556-b82e-691b86bce773" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYearOneThroughFive_019e2363-9d2a-7cb5-9d33-84647f9207ea" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYearOneThroughFive"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDate_019e2363-9d2a-71f9-9519-bbad24d597a8" xlink:to="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYearOneThroughFive_019e2363-9d2a-7cb5-9d33-84647f9207ea" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYear5Through10_019e2363-9d2a-72cc-af79-410772440c7f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYear5Through10"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDate_019e2363-9d2a-71f9-9519-bbad24d597a8" xlink:to="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYear5Through10_019e2363-9d2a-72cc-af79-410772440c7f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYear10_019e2363-9d2a-71b4-aec7-ce964215f8dc" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYear10"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDate_019e2363-9d2a-71f9-9519-bbad24d597a8" xlink:to="loc_us-gaap_DebtSecuritiesHeldToMaturityAmortizedCostExcludingAccruedInterestAfterAllowanceForCreditLossMaturityAllocatedAndSingleMaturityDateAfterYear10_019e2363-9d2a-71b4-aec7-ce964215f8dc" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesHeldToMaturityExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7275-9baf-478be64bd774" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesHeldToMaturityExcludingAccruedInterestAfterAllowanceForCreditLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesWithinOneYearFairValue_019e2363-9d2a-759a-bfda-5bf76ca70560" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_HeldToMaturitySecuritiesDebtMaturitiesWithinOneYearFairValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7275-9baf-478be64bd774" xlink:to="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesWithinOneYearFairValue_019e2363-9d2a-759a-bfda-5bf76ca70560" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterOneThroughFiveYearsFairValue_019e2363-9d2a-7d0b-983b-c78288a65481" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterOneThroughFiveYearsFairValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7275-9baf-478be64bd774" xlink:to="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterOneThroughFiveYearsFairValue_019e2363-9d2a-7d0b-983b-c78288a65481" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterFiveThroughTenYearsFairValue_019e2363-9d2a-784a-bfaf-449a5cb3bbce" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterFiveThroughTenYearsFairValue"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7275-9baf-478be64bd774" xlink:to="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterFiveThroughTenYearsFairValue_019e2363-9d2a-784a-bfaf-449a5cb3bbce" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterTenYearsFairValue_019e2363-9d2a-7061-9353-67f2b31cff87" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterTenYearsFairValue"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DebtSecuritiesHeldToMaturityExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7275-9baf-478be64bd774" xlink:to="loc_us-gaap_HeldToMaturitySecuritiesDebtMaturitiesAfterTenYearsFairValue_019e2363-9d2a-7061-9353-67f2b31cff87" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/FINANCIALDERIVATIVESScheduleofNetIncomeExpenseRecognizedDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#FINANCIALDERIVATIVESScheduleofNetIncomeExpenseRecognizedDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/FINANCIALDERIVATIVESScheduleofNetIncomeExpenseRecognizedDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_agm_TotalAmountsOfLineItemsPresentedInTheConsolidatedStatementOfIncome_019e2363-9d2a-7b3a-a5f3-7174b0f5bedb" xlink:href="agm-20260630.xsd#agm_TotalAmountsOfLineItemsPresentedInTheConsolidatedStatementOfIncome"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseOperating_019e2363-9d2a-7db3-8619-a227bac92f37" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestExpenseOperating"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_TotalAmountsOfLineItemsPresentedInTheConsolidatedStatementOfIncome_019e2363-9d2a-7b3a-a5f3-7174b0f5bedb" xlink:to="loc_us-gaap_InterestExpenseOperating_019e2363-9d2a-7db3-8619-a227bac92f37" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnDerivativeInstrumentsNetPretax_019e2363-9d2a-7bbf-9678-d9d2d3b3a3ee" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GainLossOnDerivativeInstrumentsNetPretax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_TotalAmountsOfLineItemsPresentedInTheConsolidatedStatementOfIncome_019e2363-9d2a-7b3a-a5f3-7174b0f5bedb" xlink:to="loc_us-gaap_GainLossOnDerivativeInstrumentsNetPretax_019e2363-9d2a-7bbf-9678-d9d2d3b3a3ee" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndFeeIncomeLoansAndLeases_019e2363-9d2a-7cf6-88b0-098c6843427f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestAndFeeIncomeLoansAndLeases"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_TotalAmountsOfLineItemsPresentedInTheConsolidatedStatementOfIncome_019e2363-9d2a-7b3a-a5f3-7174b0f5bedb" xlink:to="loc_us-gaap_InterestAndFeeIncomeLoansAndLeases_019e2363-9d2a-7cf6-88b0-098c6843427f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndDividendIncomeSecurities_019e2363-9d2a-7749-94d5-9105b0e72b51" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestAndDividendIncomeSecurities"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_TotalAmountsOfLineItemsPresentedInTheConsolidatedStatementOfIncome_019e2363-9d2a-7b3a-a5f3-7174b0f5bedb" xlink:to="loc_us-gaap_InterestAndDividendIncomeSecurities_019e2363-9d2a-7749-94d5-9105b0e72b51" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax_019e2363-9d2a-7277-a9bd-434420c8ad76" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax_019e2363-9d2a-7878-91da-728355a267b3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_OtherComprehensiveIncomeLossCashFlowHedgeGainLossReclassificationAfterTax_019e2363-9d2a-7277-a9bd-434420c8ad76" xlink:to="loc_us-gaap_ReclassificationFromAccumulatedOtherComprehensiveIncomeCurrentPeriodBeforeTax_019e2363-9d2a-7878-91da-728355a267b3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_019e2363-9d2a-767d-b6d2-ed9d685533a9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ChangeInUnrealizedGainLossOnFairValueHedgingInstruments1_019e2363-9d2a-7845-a55e-f1e88119c7d9" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ChangeInUnrealizedGainLossOnFairValueHedgingInstruments1"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_019e2363-9d2a-767d-b6d2-ed9d685533a9" xlink:to="loc_us-gaap_ChangeInUnrealizedGainLossOnFairValueHedgingInstruments1_019e2363-9d2a-7845-a55e-f1e88119c7d9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ChangeInUnrealizedGainLossOnHedgedItemInFairValueHedge1_019e2363-9d2a-7a07-9cd9-7fd3d42d4921" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_ChangeInUnrealizedGainLossOnHedgedItemInFairValueHedge1"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_019e2363-9d2a-767d-b6d2-ed9d685533a9" xlink:to="loc_us-gaap_ChangeInUnrealizedGainLossOnHedgedItemInFairValueHedge1_019e2363-9d2a-7a07-9cd9-7fd3d42d4921" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_GainLossOnFairValueHedgesDerivativeInterestSettlements_019e6511-5f05-7455-9b33-a5e90b305795" xlink:href="agm-20260630.xsd#agm_GainLossOnFairValueHedgesDerivativeInterestSettlements"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_019e2363-9d2a-767d-b6d2-ed9d685533a9" xlink:to="loc_agm_GainLossOnFairValueHedgesDerivativeInterestSettlements_019e6511-5f05-7455-9b33-a5e90b305795" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/FINANCIALDERIVATIVESScheduleofFairValueofFinancialAssetsandLiabilitiesDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#FINANCIALDERIVATIVESScheduleofFairValueofFinancialAssetsandLiabilitiesDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/FINANCIALDERIVATIVESScheduleofFairValueofFinancialAssetsandLiabilitiesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_agm_DerivativeLiabilityIncludingNotSubjectToMasterNettingArrangementAfterOffsetAndDeductionNetAmount_019e2363-9d2a-7bf0-ac86-8cbb262eccc4" xlink:href="agm-20260630.xsd#agm_DerivativeLiabilityIncludingNotSubjectToMasterNettingArrangementAfterOffsetAndDeductionNetAmount"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralRightToReclaimSecurities_019e2363-9d2a-7d85-b821-6998a383bf02" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeCollateralRightToReclaimSecurities"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_DerivativeLiabilityIncludingNotSubjectToMasterNettingArrangementAfterOffsetAndDeductionNetAmount_019e2363-9d2a-7bf0-ac86-8cbb262eccc4" xlink:to="loc_us-gaap_DerivativeCollateralRightToReclaimSecurities_019e2363-9d2a-7d85-b821-6998a383bf02" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralRightToReclaimCash_019e2363-9d2a-7032-aa09-ba6ed59d5f5a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeCollateralRightToReclaimCash"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_DerivativeLiabilityIncludingNotSubjectToMasterNettingArrangementAfterOffsetAndDeductionNetAmount_019e2363-9d2a-7bf0-ac86-8cbb262eccc4" xlink:to="loc_us-gaap_DerivativeCollateralRightToReclaimCash_019e2363-9d2a-7032-aa09-ba6ed59d5f5a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction_019e2363-9d2a-7d99-a902-de9ee9ce9b61" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_DerivativeLiabilityIncludingNotSubjectToMasterNettingArrangementAfterOffsetAndDeductionNetAmount_019e2363-9d2a-7bf0-ac86-8cbb262eccc4" xlink:to="loc_us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction_019e2363-9d2a-7d99-a902-de9ee9ce9b61" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-7463-adcf-dbe9952566f4" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_DerivativeLiabilityIncludingNotSubjectToMasterNettingArrangementAfterOffsetAndDeductionNetAmount_019e2363-9d2a-7bf0-ac86-8cbb262eccc4" xlink:to="loc_us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-7463-adcf-dbe9952566f4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-706e-bc7d-bab254c05c6f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_019e2363-9d2a-7b7b-939c-d45c8ae30670" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeFairValueOfDerivativeLiability"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-706e-bc7d-bab254c05c6f" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_019e2363-9d2a-7b7b-939c-d45c8ae30670" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_019e2363-9d2a-7a79-ada5-a993a7738e2d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilityFairValueGrossAsset"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-706e-bc7d-bab254c05c6f" xlink:to="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_019e2363-9d2a-7a79-ada5-a993a7738e2d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-7f2d-93aa-a6c7afb83598" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetFairValueGrossLiability_019e2363-9d2a-7093-b8cf-dc1c817cad15" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssetFairValueGrossLiability"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-7f2d-93aa-a6c7afb83598" xlink:to="loc_us-gaap_DerivativeAssetFairValueGrossLiability_019e2363-9d2a-7093-b8cf-dc1c817cad15" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_019e2363-9d2a-7516-bede-e78a18041ff3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeFairValueOfDerivativeAsset"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-7f2d-93aa-a6c7afb83598" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_019e2363-9d2a-7516-bede-e78a18041ff3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_019e2363-9d2a-767c-91b5-d503204ad212" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction_019e2363-9d2a-7f3d-b280-2e26edee0aeb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_019e2363-9d2a-767c-91b5-d503204ad212" xlink:to="loc_us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction_019e2363-9d2a-7f3d-b280-2e26edee0aeb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralObligationToReturnCash_019e2363-9d2a-7365-a949-652d4129d53c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeCollateralObligationToReturnCash"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_019e2363-9d2a-767c-91b5-d503204ad212" xlink:to="loc_us-gaap_DerivativeCollateralObligationToReturnCash_019e2363-9d2a-7365-a949-652d4129d53c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralObligationToReturnSecurities_019e2363-9d2a-7348-be7b-41871921221c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeCollateralObligationToReturnSecurities"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_019e2363-9d2a-767c-91b5-d503204ad212" xlink:to="loc_us-gaap_DerivativeCollateralObligationToReturnSecurities_019e2363-9d2a-7348-be7b-41871921221c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-7eb1-a788-7ff5835e0ec5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_019e2363-9d2a-767c-91b5-d503204ad212" xlink:to="loc_us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement_019e2363-9d2a-7eb1-a788-7ff5835e0ec5" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/LOANSScheduleofCompositionofLoanBalancesDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#LOANSScheduleofCompositionofLoanBalancesDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/LOANSScheduleofCompositionofLoanBalancesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossAndLoansHeldForSaleFairValueDisclosure_019e2363-9d2a-7e4c-a6d8-38aa9a67f74b" xlink:href="agm-20260630.xsd#agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossAndLoansHeldForSaleFairValueDisclosure"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossFeeAndLoanInProcess_019e2363-9d2a-714e-976d-b86f27690920" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossFeeAndLoanInProcess"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossAndLoansHeldForSaleFairValueDisclosure_019e2363-9d2a-7e4c-a6d8-38aa9a67f74b" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossFeeAndLoanInProcess_019e2363-9d2a-714e-976d-b86f27690920" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableUnamortizedLoanCommitmentOriginationFeeAndPremiumDiscount_019e2363-9d2a-7c9d-a4ad-64282cd33b7c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableUnamortizedLoanCommitmentOriginationFeeAndPremiumDiscount"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossAndLoansHeldForSaleFairValueDisclosure_019e2363-9d2a-7e4c-a6d8-38aa9a67f74b" xlink:to="loc_us-gaap_FinancingReceivableUnamortizedLoanCommitmentOriginationFeeAndPremiumDiscount_019e2363-9d2a-7c9d-a4ad-64282cd33b7c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7610-9836-aac5db5cef3f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_019e2363-9d2a-7099-90dc-470532c26ca3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7610-9836-aac5db5cef3f" xlink:to="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_019e2363-9d2a-7099-90dc-470532c26ca3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossAndLoansHeldForSaleFairValueDisclosure_019e2363-9d2a-7330-aa53-7cf2d1fa7dd4" xlink:href="agm-20260630.xsd#agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossAndLoansHeldForSaleFairValueDisclosure"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_019e2363-9d2a-7610-9836-aac5db5cef3f" xlink:to="loc_agm_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLossAndLoansHeldForSaleFairValueDisclosure_019e2363-9d2a-7330-aa53-7cf2d1fa7dd4" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/LOANSScheduleofFinancingReceivablesCreditQualityIndicatorsDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#LOANSScheduleofFinancingReceivablesCreditQualityIndicatorsDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/LOANSScheduleofFinancingReceivablesCreditQualityIndicatorsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearTwoOriginatedFiscalYearBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-77ba-b611-344643c8c953" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearTwoOriginatedFiscalYearBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearTwoOriginatedFiscalYearBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-77ba-b611-344643c8c953" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFiveOriginatedFourYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-74e5-a6ee-337a4c0c0895" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearFiveOriginatedFourYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFiveOriginatedFourYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-74e5-a6ee-337a4c0c0895" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestOriginatedMoreThanFiveYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-79f5-899e-8f91992c1644" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestOriginatedMoreThanFiveYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestOriginatedMoreThanFiveYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-79f5-899e-8f91992c1644" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestRevolvingWriteoff_019e2363-9d2a-73dc-bf34-4798cbfb4806" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestRevolvingWriteoff"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestRevolvingWriteoff_019e2363-9d2a-73dc-bf34-4798cbfb4806" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearThreeOriginatedTwoYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-7115-925a-da97c5905a8c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearThreeOriginatedTwoYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearThreeOriginatedTwoYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-7115-925a-da97c5905a8c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFourOriginatedThreeYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-7ae9-8c1a-d992afa79593" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearFourOriginatedThreeYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFourOriginatedThreeYearsBeforeCurrentFiscalYearWriteoff_019e2363-9d2a-7ae9-8c1a-d992afa79593" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearOneOriginatedCurrentFiscalYearWriteoff_019e2363-9d2a-7317-abe7-74577d2a88f2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearOneOriginatedCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAllowanceForCreditLossWriteoff_019e2363-9d2a-7624-a2da-510dcd360b88" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearOneOriginatedCurrentFiscalYearWriteoff_019e2363-9d2a-7317-abe7-74577d2a88f2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFiveOriginatedFourYearsBeforeCurrentFiscalYear_019e2363-9d2a-7c63-bfa6-4e35a80fc377" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearFiveOriginatedFourYearsBeforeCurrentFiscalYear"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFiveOriginatedFourYearsBeforeCurrentFiscalYear_019e2363-9d2a-7c63-bfa6-4e35a80fc377" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestOriginatedMoreThanFiveYearsBeforeCurrentFiscalYear_019e2363-9d2a-763c-a4f7-0246501e705b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestOriginatedMoreThanFiveYearsBeforeCurrentFiscalYear"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestOriginatedMoreThanFiveYearsBeforeCurrentFiscalYear_019e2363-9d2a-763c-a4f7-0246501e705b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestRevolving_019e2363-9d2a-72df-a168-f33230507306" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestRevolving"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestRevolving_019e2363-9d2a-72df-a168-f33230507306" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearThreeOriginatedTwoYearsBeforeCurrentFiscalYear_019e2363-9d2a-799c-8e67-e5f14c2ea58b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearThreeOriginatedTwoYearsBeforeCurrentFiscalYear"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearThreeOriginatedTwoYearsBeforeCurrentFiscalYear_019e2363-9d2a-799c-8e67-e5f14c2ea58b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearOneOriginatedCurrentFiscalYear_019e2363-9d2a-7792-ae8d-0d5cec13addb" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearOneOriginatedCurrentFiscalYear"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearOneOriginatedCurrentFiscalYear_019e2363-9d2a-7792-ae8d-0d5cec13addb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFourOriginatedThreeYearsBeforeCurrentFiscalYear_019e2363-9d2a-7fbb-a9aa-adbdd4a5429c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearFourOriginatedThreeYearsBeforeCurrentFiscalYear"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearFourOriginatedThreeYearsBeforeCurrentFiscalYear_019e2363-9d2a-7fbb-a9aa-adbdd4a5429c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearTwoOriginatedFiscalYearBeforeCurrentFiscalYear_019e2363-9d2a-71da-a3c9-c9dae5767059" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestYearTwoOriginatedFiscalYearBeforeCurrentFiscalYear"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_019e2363-9d2a-790a-a16f-569f5b701b76" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestYearTwoOriginatedFiscalYearBeforeCurrentFiscalYear_019e2363-9d2a-71da-a3c9-c9dae5767059" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/NOTESPAYABLEBorrowingsDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#NOTESPAYABLEBorrowingsDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/NOTESPAYABLEBorrowingsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebt_019e2363-9d2a-7273-8801-71dabdd08f48" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebt"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7214-bfbd-643d1e51df79" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtNoncurrent"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_019e2363-9d2a-7273-8801-71dabdd08f48" xlink:to="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7214-bfbd-643d1e51df79" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtCurrent_019e2363-9d2a-7893-bd0d-30b5e6e8e2dc" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtCurrent"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_019e2363-9d2a-7273-8801-71dabdd08f48" xlink:to="loc_us-gaap_LongTermDebtCurrent_019e2363-9d2a-7893-bd0d-30b5e6e8e2dc" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7bb1-8935-4ef21041deb7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtNoncurrent"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo_019e2363-9d2a-7a16-8335-6850137fca3d" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7bb1-8935-4ef21041deb7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo_019e2363-9d2a-7a16-8335-6850137fca3d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalAfterYearFive_019e2363-9d2a-7a17-8d18-6ee1ea176c07" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalAfterYearFive"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7bb1-8935-4ef21041deb7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalAfterYearFive_019e2363-9d2a-7a17-8d18-6ee1ea176c07" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFour_019e2363-9d2a-755b-b501-6d9e8324de61" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFour"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7bb1-8935-4ef21041deb7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFour_019e2363-9d2a-755b-b501-6d9e8324de61" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFive_019e2363-9d2a-705d-9b88-02b13f04ff3f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFive"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7bb1-8935-4ef21041deb7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFive_019e2363-9d2a-705d-9b88-02b13f04ff3f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree_019e2363-9d2a-7c6c-850b-e878432f3e32" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebtNoncurrent_019e2363-9d2a-7bb1-8935-4ef21041deb7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree_019e2363-9d2a-7c6c-850b-e878432f3e32" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtNetOfHedgingAdjustments_019e2363-9d2a-7fee-a448-e7338fab89f6" xlink:href="agm-20260630.xsd#agm_LongTermDebtNetOfHedgingAdjustments"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtHedgingAdjustments_019e2363-9d2a-75ef-a6ea-ed9c252c5275" xlink:href="agm-20260630.xsd#agm_LongTermDebtHedgingAdjustments"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtNetOfHedgingAdjustments_019e2363-9d2a-7fee-a448-e7338fab89f6" xlink:to="loc_agm_LongTermDebtHedgingAdjustments_019e2363-9d2a-75ef-a6ea-ed9c252c5275" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebt_019e2363-9d2a-717f-83eb-3c90aa7c73e5" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebt"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtNetOfHedgingAdjustments_019e2363-9d2a-7fee-a448-e7338fab89f6" xlink:to="loc_us-gaap_LongTermDebt_019e2363-9d2a-717f-83eb-3c90aa7c73e5" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/NOTESPAYABLECallableMediumTermNotesDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#NOTESPAYABLECallableMediumTermNotesDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/NOTESPAYABLECallableMediumTermNotesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebt_019e2363-9d2a-7024-9193-c65597d463f7" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebt"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree_019e2363-9d2a-71ad-bc86-cc38344fb982" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_019e2363-9d2a-7024-9193-c65597d463f7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearThree_019e2363-9d2a-71ad-bc86-cc38344fb982" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtMaturityAfterYearFour_019e2363-9d2a-7b69-aa11-b30aa39a0fbb" xlink:href="agm-20260630.xsd#agm_LongTermDebtMaturityAfterYearFour"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_019e2363-9d2a-7024-9193-c65597d463f7" xlink:to="loc_agm_LongTermDebtMaturityAfterYearFour_019e2363-9d2a-7b69-aa11-b30aa39a0fbb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInNextTwelveMonths_019e2363-9d2a-7464-9642-7b115d2b4c44" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInNextTwelveMonths"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_019e2363-9d2a-7024-9193-c65597d463f7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInNextTwelveMonths_019e2363-9d2a-7464-9642-7b115d2b4c44" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFour_019e2363-9d2a-7717-aac8-ccb0729e9b26" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFour"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_019e2363-9d2a-7024-9193-c65597d463f7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearFour_019e2363-9d2a-7717-aac8-ccb0729e9b26" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo_019e2363-9d2a-7419-87e5-03191ef8de1f" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LongTermDebt_019e2363-9d2a-7024-9193-c65597d463f7" xlink:to="loc_us-gaap_LongTermDebtMaturitiesRepaymentsOfPrincipalInYearTwo_019e2363-9d2a-7419-87e5-03191ef8de1f" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/NOTESPAYABLEEarliestInterestResetDateofBorrowingOutstandingDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#NOTESPAYABLEEarliestInterestResetDateofBorrowingOutstandingDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/NOTESPAYABLEEarliestInterestResetDateofBorrowingOutstandingDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtWithInterestRateReset_019e2363-9d2a-7ad3-a2e3-a72c30c28498" xlink:href="agm-20260630.xsd#agm_LongTermDebtWithInterestRateReset"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtWithInterestRateResetMaturityReminderOfTheFiscalYear_019e2363-9d2a-7c0b-80f1-a6d9115f5ec7" xlink:href="agm-20260630.xsd#agm_LongTermDebtWithInterestRateResetMaturityReminderOfTheFiscalYear"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtWithInterestRateReset_019e2363-9d2a-7ad3-a2e3-a72c30c28498" xlink:to="loc_agm_LongTermDebtWithInterestRateResetMaturityReminderOfTheFiscalYear_019e2363-9d2a-7c0b-80f1-a6d9115f5ec7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtWithInterestRateResetMaturityYearOne_019e2363-9d2a-7423-94eb-f1ddc94435fd" xlink:href="agm-20260630.xsd#agm_LongTermDebtWithInterestRateResetMaturityYearOne"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtWithInterestRateReset_019e2363-9d2a-7ad3-a2e3-a72c30c28498" xlink:to="loc_agm_LongTermDebtWithInterestRateResetMaturityYearOne_019e2363-9d2a-7423-94eb-f1ddc94435fd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtWithInterestRateResetMaturityYearTwo_019e2363-9d2a-73c5-abff-5ea7df9c7e3e" xlink:href="agm-20260630.xsd#agm_LongTermDebtWithInterestRateResetMaturityYearTwo"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtWithInterestRateReset_019e2363-9d2a-7ad3-a2e3-a72c30c28498" xlink:to="loc_agm_LongTermDebtWithInterestRateResetMaturityYearTwo_019e2363-9d2a-73c5-abff-5ea7df9c7e3e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtWithInterestRateResetMaturityYearThree_019e2363-9d2a-7085-ab68-ea0055e3ef54" xlink:href="agm-20260630.xsd#agm_LongTermDebtWithInterestRateResetMaturityYearThree"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtWithInterestRateReset_019e2363-9d2a-7ad3-a2e3-a72c30c28498" xlink:to="loc_agm_LongTermDebtWithInterestRateResetMaturityYearThree_019e2363-9d2a-7085-ab68-ea0055e3ef54" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtWithInterestRateResetMaturityYearFour_019e2363-9d2a-747d-aad3-94e59559014f" xlink:href="agm-20260630.xsd#agm_LongTermDebtWithInterestRateResetMaturityYearFour"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtWithInterestRateReset_019e2363-9d2a-7ad3-a2e3-a72c30c28498" xlink:to="loc_agm_LongTermDebtWithInterestRateResetMaturityYearFour_019e2363-9d2a-747d-aad3-94e59559014f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_LongTermDebtWithInterestRateResetMaturityAfterYearFour_019e2363-9d2a-7ec1-832b-2dea5dcf20c7" xlink:href="agm-20260630.xsd#agm_LongTermDebtWithInterestRateResetMaturityAfterYearFour"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_LongTermDebtWithInterestRateReset_019e2363-9d2a-7ad3-a2e3-a72c30c28498" xlink:to="loc_agm_LongTermDebtWithInterestRateResetMaturityAfterYearFour_019e2363-9d2a-7ec1-832b-2dea5dcf20c7" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/FAIRVALUEDISCLOSURESScheduleofFairValueMeasurementsDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#FAIRVALUEDISCLOSURESScheduleofFairValueMeasurementsDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/FAIRVALUEDISCLOSURESScheduleofFairValueMeasurementsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsFairValueDisclosure_019e2363-9df3-7733-ab00-a9abcfa5def3" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_AssetsFairValueDisclosure"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9df3-75b0-b176-bec48435dccf" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_019e2363-9df3-7733-ab00-a9abcfa5def3" xlink:to="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_019e2363-9df3-75b0-b176-bec48435dccf" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssets_019e2363-9df3-7ea7-a59f-efd9ac7a119e" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeAssets"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_019e2363-9df3-7733-ab00-a9abcfa5def3" xlink:to="loc_us-gaap_DerivativeAssets_019e2363-9df3-7ea7-a59f-efd9ac7a119e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssetsFairValueDisclosure_019e2363-9df3-76eb-bece-527e9a393b6c" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_OtherAssetsFairValueDisclosure"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_019e2363-9df3-7733-ab00-a9abcfa5def3" xlink:to="loc_us-gaap_OtherAssetsFairValueDisclosure_019e2363-9df3-76eb-bece-527e9a393b6c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesFairValueDisclosure_019e2363-9df3-77b4-a6dd-55fc8a8b8991" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_LiabilitiesFairValueDisclosure"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilities_019e2363-9df3-795f-8a27-b7dfaecffcdd" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_DerivativeLiabilities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesFairValueDisclosure_019e2363-9df3-77b4-a6dd-55fc8a8b8991" xlink:to="loc_us-gaap_DerivativeLiabilities_019e2363-9df3-795f-8a27-b7dfaecffcdd" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.farmermac.com/role/BUSINESSSEGMENTREPORTINGScheduleofSegmentReportingInformationDetails" xlink:type="simple" xlink:href="agm-20260630.xsd#BUSINESSSEGMENTREPORTINGScheduleofSegmentReportingInformationDetails"/>
  <link:calculationLink xlink:role="http://www.farmermac.com/role/BUSINESSSEGMENTREPORTINGScheduleofSegmentReportingInformationDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Assets_019e2363-9df3-7538-926b-df8e959a198b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_Assets"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_UnallocatedAssets_019e2363-9df3-7ab3-a2e4-7d2e14b41eb7" xlink:href="agm-20260630.xsd#agm_UnallocatedAssets"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9df3-7538-926b-df8e959a198b" xlink:to="loc_agm_UnallocatedAssets_019e2363-9df3-7ab3-a2e4-7d2e14b41eb7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_OffBalanceSheetProgramAssets_019e2363-9df3-7bd6-acbf-5b5b8148abd7" xlink:href="agm-20260630.xsd#agm_OffBalanceSheetProgramAssets"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9df3-7538-926b-df8e959a198b" xlink:to="loc_agm_OffBalanceSheetProgramAssets_019e2363-9df3-7bd6-acbf-5b5b8148abd7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_OnAndOffBalanceSheetProgramAssetsAtPrincipalBalance_019e2363-9df3-73ca-ac04-baa59c773a9a" xlink:href="agm-20260630.xsd#agm_OnAndOffBalanceSheetProgramAssetsAtPrincipalBalance"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_019e2363-9df3-7538-926b-df8e959a198b" xlink:to="loc_agm_OnAndOffBalanceSheetProgramAssetsAtPrincipalBalance_019e2363-9df3-73ca-ac04-baa59c773a9a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_NetEffectiveSpread_019e2363-9df3-768e-83e3-775009dafc14" xlink:href="agm-20260630.xsd#agm_NetEffectiveSpread"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_ReconcilingAdjustmentsFromNetInterestIncomeToNetEffectiveSpreadNet_019e2363-9df3-793b-8e3a-d5ed6c661a60" xlink:href="agm-20260630.xsd#agm_ReconcilingAdjustmentsFromNetInterestIncomeToNetEffectiveSpreadNet"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_NetEffectiveSpread_019e2363-9df3-768e-83e3-775009dafc14" xlink:to="loc_agm_ReconcilingAdjustmentsFromNetInterestIncomeToNetEffectiveSpreadNet_019e2363-9df3-793b-8e3a-d5ed6c661a60" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndDividendIncomeOperating_019e2363-9df3-7569-881a-b32acbbf383b" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestAndDividendIncomeOperating"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_NetEffectiveSpread_019e2363-9df3-768e-83e3-775009dafc14" xlink:to="loc_us-gaap_InterestAndDividendIncomeOperating_019e2363-9df3-7569-881a-b32acbbf383b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseOperating_019e2363-9df3-7093-91d5-7f8cec82a51a" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_InterestExpenseOperating"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_NetEffectiveSpread_019e2363-9df3-768e-83e3-775009dafc14" xlink:to="loc_us-gaap_InterestExpenseOperating_019e2363-9df3-7093-91d5-7f8cec82a51a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_019e2363-9df3-78aa-8ba0-de96cc2405cc" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_NetIncomeLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SegmentReportingOtherItemAmount_019e2363-9df3-750d-bd64-1709950546b2" xlink:href="https://xbrl.fasb.org/us-gaap/2026/elts/us-gaap-2026.xsd#us-gaap_SegmentReportingOtherItemAmount"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019e2363-9df3-78aa-8ba0-de96cc2405cc" xlink:to="loc_us-gaap_SegmentReportingOtherItemAmount_019e2363-9df3-750d-bd64-1709950546b2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_NetEffectsOfDerivativesAndTradingSecurities_019e2363-9df3-790c-adcb-330321851972" xlink:href="agm-20260630.xsd#agm_NetEffectsOfDerivativesAndTradingSecurities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019e2363-9df3-78aa-8ba0-de96cc2405cc" xlink:to="loc_agm_NetEffectsOfDerivativesAndTradingSecurities_019e2363-9df3-790c-adcb-330321851972" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_SegmentCoreEarnings_019e2363-9df3-7ecd-9a91-a10f3e37b31b" xlink:href="agm-20260630.xsd#agm_SegmentCoreEarnings"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019e2363-9df3-78aa-8ba0-de96cc2405cc" xlink:to="loc_agm_SegmentCoreEarnings_019e2363-9df3-7ecd-9a91-a10f3e37b31b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_IncomeTaxEffectRelatedToReconcilingItems_019e2363-9df3-714e-bcf6-7a16f1cc499b" xlink:href="agm-20260630.xsd#agm_IncomeTaxEffectRelatedToReconcilingItems"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_019e2363-9df3-78aa-8ba0-de96cc2405cc" xlink:to="loc_agm_IncomeTaxEffectRelatedToReconcilingItems_019e2363-9df3-714e-bcf6-7a16f1cc499b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_SegmentCoreEarnings_019e2363-9df3-7636-ba6f-b502d76665eb" xlink:href="agm-20260630.xsd#agm_SegmentCoreEarnings"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_FinancingReceivableExcludingAccruedInterestCreditLossExpenseReversalAdjusted_019e2363-9df3-7549-b577-992d0c0bd197" xlink:href="agm-20260630.xsd#agm_FinancingReceivableExcludingAccruedInterestCreditLossExpenseReversalAdjusted"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_SegmentCoreEarnings_019e2363-9df3-7636-ba6f-b502d76665eb" xlink:to="loc_agm_FinancingReceivableExcludingAccruedInterestCreditLossExpenseReversalAdjusted_019e2363-9df3-7549-b577-992d0c0bd197" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_InvestmentBankingAdvisoryBrokerageAndUnderwritingFeesAndCommissionsAdjusted_019e2363-9df3-7418-b9e8-f1e5d0bfc9ad" xlink:href="agm-20260630.xsd#agm_InvestmentBankingAdvisoryBrokerageAndUnderwritingFeesAndCommissionsAdjusted"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_SegmentCoreEarnings_019e2363-9df3-7636-ba6f-b502d76665eb" xlink:to="loc_agm_InvestmentBankingAdvisoryBrokerageAndUnderwritingFeesAndCommissionsAdjusted_019e2363-9df3-7418-b9e8-f1e5d0bfc9ad" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_NetEffectiveSpread_019e2363-9df3-7d65-a99b-8c90e5cd8db5" xlink:href="agm-20260630.xsd#agm_NetEffectiveSpread"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_SegmentCoreEarnings_019e2363-9df3-7636-ba6f-b502d76665eb" xlink:to="loc_agm_NetEffectiveSpread_019e2363-9df3-7d65-a99b-8c90e5cd8db5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLossesAdjusted_019e2363-9df3-752f-8630-e2610d17c01e" xlink:href="agm-20260630.xsd#agm_NoninterestExpenseExcludingLoanLeaseAndOtherLossesAdjusted"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_SegmentCoreEarnings_019e2363-9df3-7636-ba6f-b502d76665eb" xlink:to="loc_agm_NoninterestExpenseExcludingLoanLeaseAndOtherLossesAdjusted_019e2363-9df3-752f-8630-e2610d17c01e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_OtherNonInterestIncomeExpenseAdjusted_019e2363-9df3-73c4-9b48-cdabb65b1c7d" xlink:href="agm-20260630.xsd#agm_OtherNonInterestIncomeExpenseAdjusted"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_SegmentCoreEarnings_019e2363-9df3-7636-ba6f-b502d76665eb" xlink:to="loc_agm_OtherNonInterestIncomeExpenseAdjusted_019e2363-9df3-73c4-9b48-cdabb65b1c7d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_agm_IncomeTaxExpenseBenefitAdjusted_019e2363-9df3-7520-bca5-684d15052728" xlink:href="agm-20260630.xsd#agm_IncomeTaxExpenseBenefitAdjusted"/>
    <link:calculationArc order="6" weight="-1.0" xlink:arcrole="https://xbrl.org/2023/arcrole/summation-item" xlink:from="loc_agm_SegmentCoreEarnings_019e2363-9df3-7636-ba6f-b502d76665eb" xlink:to="loc_agm_IncomeTaxExpenseBenefitAdjusted_019e2363-9df3-7520-bca5-684d15052728" xlink:type="arc"/>
  </link:calculationLink>
</link:linkbase>
