Lumping everything together hides some important facts.
I took this graphic of the 2018 Federal Budbget from the Wikipedia page,
United States Federal Budget:
So we have mandatory spending and discretionary spending as you kind of broke out with your second graphic. From mine we have these groupings:
Outlays $4.1 trillion
- Mandatory $2.523 trillion
- Social Security $982 billion
- Medicare $582 billion -- minus income from premiums and other offsetting receipts
- Medicaid $389 billion
- Other $570 billion -- Outlays for unemployment compensation, federal civilian and military retirement, some veterans' benefits, earned income tax credit, Supplemental Nutrition Assitance Program, and other mandatory programs minus income from offsetting receipts
- Discretionary $1.262 trillion
- Defense $623 billion
- Nondefense $639 billion -- outlays for many programs related to transportation, education, veterans' benefits, health, housing assistance, and other activities
- Net Interest $325 billion
But where are the revenues coming from that pay for that? This is the part the gets obscured:
Revenues $3.3 trillion
- Dedicated to specific programs -- $1.2 trillion
- Payroll Taxes $1.2 trillion -- fund social insurance programs primarily SS and Medicare A
- General Fund -- $2.176 trillion
- Individual Income Taxes $1.7 trillion
- Corporate income taxes $205 billion
- Other $271 billion -- excise taxes, estate and gift taxes, customs duties, remittances from Federal Reserve, misc fees and fines
So any discussion of the deficit requires that we define specifically where the deficit comes from, namely what specific revenues and specific outlays go into calculating the deficit. That must be known in order to figure out which factors cause the deficit and therefore which factors could be adjusted to reduce or eliminate the deficit.
Both Social Security and Medicare Part A (Parts B, C, & D are insurance programs, two of them
private insurance, funded by premiums paid by recipients) are funded by payroll taxes levied specially for them and which cannot be used for any other purpose. As such, they cannot and do no play any part in the deficit. Since they are not factors contributing to the deficit, adjusting them would have no effect on the deficit.
Also, these figures are for the 2018 Budget. We need to see the figures for the 2019 Budget, which I believe was the first one based on the GOP's tax scam and which greatly increased defense spending from $623 billion to something like $800 billion (as I recall). And when we crunch those numbers, we will need to keep straight where specific sources of revenue are going (eg, payroll taxes going to Social Security and to Medicare A).
Also keep in mind that Fiscal Year 2019 ended a couple weeks ago and that we are currently in FY 2020 and hence under the 2020 Budget.