What’s the difference between yathābhūta and yathābhūtaṃ? I’ve been reading about this term and have found it written in both ways. I don’t know if the difference is related to some kind of verb form.
Yathābhūta is not correct in pali-sentence. We have to put the declension-mark at the end of yathābhūta, such as  yathābhūtaṃ, before put it in the sentence.

Yathābhūta is adjective/adverb which is not complete, not ready to use, because the properties of word (vibhatti;case-endings;declension):  preposition(sambandha), amount(vacana), and gender(liṅga), etc., must put at the end of every words, except ready-made-noun (nipāta), some standalone-prefix (upasagga-nipāta; I'm not sure for linguistic name), and compound-word (samāsa). So, it can not come alone, and you can not found only yathābhūta  alone in pāli. It should to be yathābhūtaṃ (si-vibhatti), yathābhūtañāṇadassanaṃ (Deleted vibhatti because of compound-word; Vibhatti still be, but it disappear by pali-processing), yathābhūtena (nā-vibhatti), etc.

See: http://www.buddha-vacana.org/toolbox/noundec.html

For the explanation of the term "yathābhūta":

Yathā ... tathā = How it is ... as it is.

Bhūta = arising/becomming = upatti-bhava-paṭiccasamuppāda = upatti-becoming = jāti(rebirth) + jarā&amp;maraṇa (old-age&amp;death). bhū-root[as arise-term]+ta-suffix[as verb].

Arising of what? Arising of 5 aggregates in paṭiccasamuppāda-cycle. So: 


in Sutta. Saṃ. Saḷa. Dukkhadhammasutta, buddha use yathābhūta
as arising and vanishing of 5 aggregates;
In Sutta. Saṃ. Ni. Dukkhasutta, buddha describe arising and
vanishing of 5 aggregates as paṭiccasamuppāda;
In Khandhapabba of Sutta. Ma. Mū. Mahāsatipaṭṭhānasutta, 
buddha describe arising and vanishing of 5 aggregates as
udayabbaya-ñāṇa-niddeso;
Also, in Khandhapabba, buddha describe vipassanā in arising
and vanishing of 5 aggregates as "samudayavayadhammānupassī
vā" which commentary refer that dhamma-term as
Dukkhadhammasutta;
So, in Sutta. Khu. Paṭisambhidāmaggo
udayabbayānupassanāñāṇa-niddesa &amp; the path of purification
maggāmaggañāṇadassanavisuddhiniddesa udayabbayañāṇakathā, Master
Sāriputta and Master Buddhaghosa describe udayabbaya as
paṭiccasamuppāda as well.


So, yathābhūta-ñāṇa is understanding of arising of 5 aggregates in paṭiccasamuppāda-cycle. 

Another, I also describe yathābhūta in this answer: https://buddhism.stackexchange.com/a/26702/10100

Buddha have to cut the big sutta in DN/MN for the students who not smart enough to enlighten/understand/memorize at once. So, you can notice my reference are from DN&amp;MN&amp;SN&amp;KN, and actually AN as well.

Pāli has a very strong structure. This is the reason why we can understand tipitaka's content by just fluent reciting&amp;memorizing. But because of the complicate detail of Dhamma, so when we translate tipitaka to the other languages, such as english or especilly thai, we will lose many important words' properties. Then we can not understand/analysis/find the fact from some translation.

"Svākkhāto bhagavatā dhammo-the best dhamma was taught by buddha." is not just the psalms, but it is the fact by the linguistics and the truth.