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

📄 ldpc.h

📁 介绍了ldpc编码相关的设计与实现
💻 H
字号:
#ifndef _LDPC_H_
#define _LDPC_H_

#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <math.h>

short		Column;
short		H_row;
short		G_row;

/*Define the LDPC code parameters structure*/
struct	LDPCParam
{
	short	mat_param[5];
	short	iterC;
	short	*MatCol;
	short	*MatRow;
	short	*GMatrix;
};

struct LDPCParam	ldpc_param;

void LDPC_init(struct LDPCParam *p_ldpc_param, FILE *fpLDPC);

void init_mat_para(short *mat_para, FILE *f_H_data);
void array_sort (short *in , short length , short init_min);
void gauss_elimate_to_P_I (short *mat_col , short *mat_row , short **t , short *rank , short *mat_para);
void Construct_H_Matrix (short *mat_para , short *mat_col , short *mat_row, FILE *f_H_data);
void Construct_G_Matrix (short *mat_col , short *mat_row , short **gen , short *mat_para);

void LDPC_encode(short *gen, short *input, short *output, short *mat_para);
double correct_factor(double x,double y);

void BP_decoding(double		*llr_in,
				 double		*llr_out,
				 short		*dec_out,
				 short		*mat_col,
				 short		*mat_row,
				 short		*mat_param,
				 short		iterN);


#endif

⌨️ 快捷键说明

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