# Extracting filter coefficients from a transfer function

What is the correct way to extract coefficients (in a form I could use in RecurrenceFilter) from a filter which I have represented as a Mathematica transfer function object, ie. something of the form TransferFunctionModel[...]? I can easily extract the various parts of this object using array indices, but surely there is an "official" method?

I looked at the Mathematica documentation. But, for example, the coefficients used in In[101] here look like they've been copied manually from In[92], rather than obtained through a coefficient extraction function.

There is more than one way to get the coefficients. The following will work for rational, scalar systems, without delays - which is what is handled by RecurrenceFilter.
tfd1 = TransferFunctionExpand[tfd][s][[1, 1]]