⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pnutil.c

📁 在linux系统下开发研究移动通信的工具型代码
💻 C
字号:
/* * $Log: pnutil.c,v $ * Revision 1.1  2000/05/03 14:30:04  bjc97r * Initial revision * */char *_pnutil_id = "$Id: pnutil.c,v 1.1 2000/05/03 14:30:04 bjc97r Exp $";int pn_xcorr( char *pn1, char *pn2, int offset, int size )  /* It finds the cross-correlation of the two given sequence in pn[].     size is the array size of pn?[].     The calculated cross-correlation before scaling is returned. */{  int val;  /* calculated auto-correlation value */  int i, j; /* loop indices */    val = 0;  for( i = 0, j = offset; i < size; i++, j++ ) {    if ( j >= size ) j -= size;    if ( pn1[i] == pn2[j] )      val++;    else      val--;  }    return val;}int pn_acorr( char *pn, int offset, int size )  /* It finds the auto-correlation of the given sequence in pn[].     size is the array size of pn[].     The calculated auto-correlation before scaling is returned. */{  return pn_xcorr( pn, pn, offset, size );}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -