metrics.h
来自「wcdma模型」· C头文件 代码 · 共 93 行
H
93 行
/* | | Copyright disclaimer: | This software was developed at the National Institute of Standards | and Technology by employees of the Federal Government in the course | of their official duties. Pursuant to title 17 Section 105 of the | United States Code this software is not subject to copyright | protection and is in the public domain. | | We would appreciate acknowledgement if the software is used. |*//* | Project: WCDMA simulation environment | Module: Viterbi path metric calculation. | Author: Tommi Makelainen, Nokia/NIST | Date: January 11, 1999 | | History: | January 11, 1999 Tommi Makelainen | Initial version. | | February 16, 1999 Tommi Makelainen | Corrected branch metric calculation for soft | bits. | */#ifndef METRICS_H#define METRICS_H /* --------- T Y P E D E F I N I T I O N S --------------------- */enum metric_type_type { HAMMING_METRIC = 0, SOFT_METRIC }; struct MetricTable_type{ double Metric_Table[8][8]; enum metric_type_type Metric_Type; double Soft_metric_probabilities[2][64]; int Soft_metric_weight[2][64]; };typedef struct MetricTable_type MetricTable;/* -------------------------------------------------------------- */ void MetricTable_R1o3_Init( MetricTable* this, enum metric_type_type metric_type, double bit_probabilites_0[], double bit_probabilites_1[], int no_of_probabilities); void MetricTable_R1o2_Init( MetricTable* this, enum metric_type_type metric_type, double bit_probabilites_0[], double bit_probabilites_1[], int no_of_probabilities); double MetricTable_SoftSymbolMetric( MetricTable* this, int rx_symbol, int tx_symbol); double MetricTable_R1o2_SoftSymbolMetric( MetricTable *this, int rx_symbol, int tx_symbol);double MetricTable_R1o3_SoftSymbolMetric( MetricTable *this, int rx_symbol, int tx_symbol);double MetricTable_R1o2_GetBranchMetric( MetricTable* this, int rx_symbol, double soft_metric, int tx_symbol);double MetricTable_R1o3_GetBranchMetric( MetricTable *this, int rx_symbol, double soft_metric, int tx_symbol);#endif
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?