hkl-unit-private: hkl Reference Manual

## hkl-unit-private hkl-unit-private |

## Functions

HklUnit * | hkl_unit_dup ()
void | hkl_unit_free ()
int | hkl_unit_compatible ()

## Types and Values

struct | HklUnitDimension
#define | HklDPlaneAngle
#define | HklDLength
struct | HklUnit
double | res

## Description

## Functions

### hkl_unit_dup ()

    HklUnit *
    hkl_unit_dup (const HklUnit *self);

copy an Hklunit

[skip]

#### Returns

the copied HklUnit (memory must be release with hkl_unit_free)

### hkl_unit_free ()

    void
    hkl_unit_free (HklUnit *self);

release the memory of an HklUnit

[skip]

### hkl_unit_compatible ()

    int
    hkl_unit_compatible (const HklUnit *unit1,
                         const HklUnit *unit2);

check if two units are compatible.

[skip]

#### Parameters

self | the first `HklUnit` |
unit | the second `HklUnit` to check |

#### Returns

TRUE or FALSE

## Types and Values

### struct HklUnitDimension

    struct HklUnitDimension {
    	int l; /* Length */
    	int m; /* Mass */
    	int t; /* Time */
    	int i; /* Electric current */
    	int th; /* Thermodynamic temperature */
    	int n; /* Amount of substance */
    	int j; /* Luminous intensity */
    };

### HklDPlaneAngle

    #define HklDPlaneAngle {0, 0, 0, 0, 0, 0, 0}

### HklDLength

    #define HklDLength {1, 0, 0, 0, 0, 0, 0}

### struct HklUnit

    struct HklUnit {
    	HklUnitDimension dimension;
    	double factor;
    	char const *name;
    	char const *repr;
    };

### res

    	double res = 1.0;