There is an awful lot of maths and not a lot of code. As I am far from being an expert on Digital Signal Processing I am going to skip that aspect of the book by issuing an invitation to any reader who specialises in that area to review this book from that viewpoint (just volunteer and I will send you the review copy unless someone else has beaten you to it.)
The choice of C (supported by some assembler level programming) seems reasonable to me, after all C was designed as a systems language. So let me examine some of the author's code. On page 59 I find the following (after some pre-processor directives and the definition of A as a 32 by 32
staticarray of
double).
void main() { but int i, j; static n=4; double a[11][21]; void ge(); { for(j=0; j<2*n; j++) { for (i=0; iI will stop there because I think this is enough to scare any self respecting programmer. Ignore the return type of main() as the code calls exit() to terminate. But what is the purpose of that
static. Surely the writer does not intend to callmainrecursively? No he does not. I think thatstaticbeconstbecause I think he wants to produce a manifest constant.Next, why the dimensions of
a? I think, after careful study, that his intention is to ignore the zeroeth column and row and have an array with a two to one ratio between rows and columns. But what else is significant? That is why a 10 by 20 array? And so the questions mount. The code is completely incomprehensible. I know what every line does but have absolutely no idea as to how they are related.Then we have that archaic declaration of a function inside the body of
main(). A complete waste because its first use later in the code will do just as well. A prototype out front (and a meaningful name) would be much more use.How about that nested block on the next line? What does the writer think it does? Of course it actually does nothing.
I hope the author's knowledge of DSPs and numerical methods is of a higher standard because the book does not pass muster on the coding side.