If I have three criteria for the domain of $ m\in\{1,2,3,4,5,6,…,22\}$ as

$ $ f(m)= \cos \left(\frac{\pi ^5 m}{4}\right)\quad for \quad m=3,6,12,15,21$ $ $ $ g(m)=\frac{1}{\sin \left(\frac{\pi m}{3}\right)}\quad for \quad m=1,2,4,5,7,8,10,11,13,14,16,17,19,20,22$ $ $ $ h(m)=10\quad for \quad m=9,18$ $

then how can I have one DiscretePlot for all $ m\in\{1,2,3,4,5,6,…,22\}$ , and then join the adjacent numbers.

`f[m_] = Cos[(m (\[Pi]^5) )/4] for m = 3, 6, 12, 15, 21`

`g[m_] = Sin[(m \[Pi] )/3]^-1 for m = 1, 2, 4, 5, 7, 8, 10, 11, 13, 14, 16, 17, 19, 20, 22 `

`h[m_] = 10 for m = 9, 18`