File: genarray.c

package info (click to toggle)
cmix 2.0.12-6
  • links: PTS
  • area: main
  • in suites: etch, etch-m68k
  • size: 6,924 kB
  • ctags: 6,063
  • sloc: cpp: 27,155; ansic: 11,923; sh: 3,000; exp: 2,270; yacc: 1,724; makefile: 1,251; lex: 488; perl: 278
file content (16 lines) | stat: -rw-r--r-- 357 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
#include "fft.h"
#include <math.h>

REAL orig_real[N], orig_imag[N];

/* ---------------------------------------------------------------------- */
/* Generate some silly test data, based on q                              */

void generate_data(int q) {
  int x; 
  for (x = 0; x < N; x++) {
    orig_real[x] = sin(x / q);
    orig_imag[x] = 0.0 / q;
  }
}