forked from SZV10X_Software/SZV103_FM33A0xxEV_SiZhu

周巍
2024-04-11 91ef77c00ed797b1048c5187f416e351e646a009
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
 
 
#ifndef _FACTORTAB_H
#define _FACTORTAB_H
#include "sys.h"
 
#define        TEMPERATURE_HIGH_LEVEL        40
#define        TEMPERATURE_LOW_LEVEL        -10
#define        TEMPERATURE_TAB                1
#define        PRESSURE_HIGH_LEVEL            1600
#define        PRESSURE_LOW_LEVEL            100
#define        PRESSURE_TAB                    20
 
#define        PRESSURE_NUM_ONE_TEMP        (((PRESSURE_HIGH_LEVEL - PRESSURE_LOW_LEVEL)/PRESSURE_TAB) + 1)
#define        TEMPERATURE_NUM                ((TEMPERATURE_HIGH_LEVEL - TEMPERATURE_LOW_LEVEL) + 1)
 
#define        TABLE1                            1
#define        TABLE2                            2
#define        TABLE3                            3
 
float     get_factor(float temperature, float pressure, u8 tabfactnum);
float          getstandardcompressibility(float fact, float temperature, float pressure, u8 tabfactnum);
#endif