With paradigm and paradigmatic, just as with phlegm and phlegmatic, English only allows that g to be sounded when you can split a syllable. (The unassimilated version with a final ‑a technically does still exist, but the OED calls it “rare”.)
This is all because the phonotactics of English (the rules for how one can arrange its phonemes) do not permit a /g/ followed by a nasal at the end the word. You see the same thing occurring with diaphragm, or for that matter with the simpler phlegm, about which the OED writes that:
The g has probably never been pronounced except in disyllabic forms in ‑a.
Indeed, this same thing happens with all the words with a g and a nasal at their end, including
None of those is pronounced with a /g/, and probably never has been in English. At most they once had a /ɲ/ sound there way back when they ended with an unstressed vowel that we no longer write, all thanks to French.
When these words came into English, standard spelling did not yet exist. Many passed through French, where they were written with a final ‑e, or were modelled after words that were. French for example has paradigme, diaphragme. And words with a final unstressed ‑e like those came to be written without it once it stopped being said, at which point there was no chance to put the /g/ in one syllable and the nasal is the next.
You might as well ask why the g is “silent” in the Italian city of Bologna, pronounced of course with a geminated or “long” /ɲ/ in Italian or as /nj/ in English. In Italian, just as in French, the wheels of time have ground it down so that the ‹gn› spelling is now a digraph (a two-letter combo) representing /ɲ/, not as two separate letters each with their own sound.
Notice how that same thing happens with the French region of Bourgogne (Burgundy in English). Even when it’s spelled Borgogna in Italian, nobody “says” that g in French or Italian. It’s got a /ɲ/ phoneme there, which is why the Spanish sensibly spell it Borgoña to avoid confusing people.
We tend to keep the written ‹g› in English words like this, even though we “can’t” say it there at the end of the word right before that final nasal. This helps us understand the shared relationship with longer words like paradigmatic that have a vowel after the nasal, which allows the /g/ to “reappear”. But we probably no more ever said it in paradigm(e) than we ever said it in phlegm. Our phonotactic rules forbid it.
This likely also explains why apophthegm from Greek ἀπόϕθεγμα is more often spelled apothegm these days. We can’t say a lot of those letters, so we’ve given up writing them.
In comments, someone asked why aligning doesn’t cause the /g/ to “reappear” in split syllables as it seems to with paradigmatic (cf. French paradigmatique). The answer is that ‑ing is an English verbal inflection not a Classical or Romance one, but align the verb came to us from Middle French alinher, now¹ spelled aligner in Modern French. That means ther was never a /g/ phoneme for anyone there historically the way there was in the Greek παραδειγματικός. Part of the real, spoken language, our ‑ing verbal inflection in English is 100% regular with zero exceptions, so it cannot produce something out of nothing.
In comments, the asker further inquired as to whether the word went through a bunch of different spellings historically the way phlegm did, and why the last syllable has a diphthong:
“Middle English fleem, fleume, from Old French fleume, from late Latin phlegma ‘clammy moisture (of the body)’, from Greek phlegma ‘inflammation’, from phlegein ‘to burn’. The spelling change in the 16th century was due to association with the Latin and Greek.” was there a similar change in spelling for paradigm? I didn't find anything. And why the /ʌɪ/ sound and not /ɪ/?
The answer to these questions is that paradigm didn’t show up in English until hundreds of years after the word we now spell as phlegm did. For paradigm, the first actual English citation (rather than Latin) is from 1493 in Caxton, written paradygmes and translating French.
And the reason it’s today pronounced [ˈpæɹədʌɪm] or [ˈpeɹəˌdɑɪm] with a diphthong in the last syllable is because the Great Vowel Shift² notoriously changed the “long” i sound /iː/ into a diphthong. English spelling was more or less frozen before the GVS, which explains a great deal of confusion compared with the standard Latin values for vowels that everyone else but us uses.
Because the ‹nh› and ‹gn› digraphs represent the same /ɲ/ phoneme under different orthographic traditions. Old Occitan / Provençal, being langues d’oc, used ‹nh› for it, as does Catalan which is also in that group. The Galician–Portuguese language deliberately broke from Castilian orthographic habits and instead adopted ‹nh› during the early 1300s thanks to the famous poet Dinis I, king of Portugal and the Algarve, because of the prestige position which the troubadours’ tongue held in that age. In contrast, the “langues d’oïl” branches of French, of which Modern French is a descendant, used the ‹gn› digraph just like Modern Italian does for this /ɲ/ sound. Castilian and Asturian use ‹ñ› (earlier ‹nn›) for the same /ɲ/ sound in those languages as the ‹nh› and ‹gn› digraphs do in theirs. Uncountably many research papers and scholarly tomes have been written about the origin of the palatalized nasal [ɲ] and lingual [ʎ] sounds during the transition from Latin to Modern Romance, no matter the spelling.
The GVS was a chain shift that reassigned new sounds to all the long vowels in English in a bizarre way that all other users of the Latin alphabet forevermore hate us for. :)