ldpc_head.h

来自「LDPC的完整c语言开发源程序代码」· C头文件 代码 · 共 44 行

H
44
字号
#include <stdio.h>
#include <stdlib.h>
#include <math.h>
#include <time.h>
#include <iostream.h>
#include <string.h>

#define limit	1e-50
#define pi		3.1415926
#define iterative_num	50
#define MAX		1e10



struct matrix_bit
{
	unsigned int N;     //the blocklength of the codeword 码长
	unsigned int M1;    //the number of message bits of a codeword 信息位
	unsigned int M;     //rows of parity check matrix H 奇偶校验矩阵的行数
	unsigned int G_mcw; //the max column weight of G    生成矩阵的最大列数
	unsigned int H_mrw; //the max row weight of H       奇偶校验矩阵的最大列数
	unsigned int *H;    //the parity check matrix       奇偶校验矩阵
	unsigned int *G;    //the generator matrix          生成矩阵
};

struct code
{
	unsigned int length;
	double		 *codeword;
};

struct node
{
	int row;
	int col;
	struct node *left;
	struct node *right;
	struct node *up;
	struct node *down;
	double R;
	double Q;
};

⌨️ 快捷键说明

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