1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
// <auto-generated>
// This code was generated by the UnitCodeGenerator tool
//
// Changes to this file will be lost if the code is regenerated
// </auto-generated>
//! # Force based converters
/// Dynes conversion functions
pub mod dynes {
/// Converts the supplied Dynes value to Newtons
/// # Arguments
/// * `value` - The Dynes input value
pub fn to_newtons(value: f64) -> f64 {
return value / 100000.0;
}
/// Converts the supplied Dynes value to Poundals
/// # Arguments
/// * `value` - The Dynes input value
pub fn to_poundals(value: f64) -> f64 {
return value / 13825.4954376;
}
/// Converts the supplied Dynes value to Kilogram-force
/// # Arguments
/// * `value` - The Dynes input value
pub fn to_kilogramforce(value: f64) -> f64 {
return value / 980665.0;
}
}
/// Kilogram-force conversion functions
pub mod kilogramforce {
/// Converts the supplied Kilogram-force value to Newtons
/// # Arguments
/// * `value` - The Kilogram-force input value
pub fn to_newtons(value: f64) -> f64 {
return value * 9.80665;
}
/// Converts the supplied Kilogram-force value to Dynes
/// # Arguments
/// * `value` - The Kilogram-force input value
pub fn to_dynes(value: f64) -> f64 {
return value * 980665.0;
}
/// Converts the supplied Kilogram-force value to Poundals
/// # Arguments
/// * `value` - The Kilogram-force input value
pub fn to_poundals(value: f64) -> f64 {
return value * 70.93163528397;
}
}
/// Newtons conversion functions
pub mod newtons {
/// Converts the supplied Newtons value to Dynes
/// # Arguments
/// * `value` - The Newtons input value
pub fn to_dynes(value: f64) -> f64 {
return value * 100000.0;
}
/// Converts the supplied Newtons value to Poundals
/// # Arguments
/// * `value` - The Newtons input value
pub fn to_poundals(value: f64) -> f64 {
return value * 7.23301;
}
/// Converts the supplied Newtons value to Kilogram-force
/// # Arguments
/// * `value` - The Newtons input value
pub fn to_kilogramforce(value: f64) -> f64 {
return value / 9.80665;
}
}
/// Poundals conversion functions
pub mod poundals {
/// Converts the supplied Poundals value to Newtons
/// # Arguments
/// * `value` - The Poundals input value
pub fn to_newtons(value: f64) -> f64 {
return value / 7.23301;
}
/// Converts the supplied Poundals value to Dynes
/// # Arguments
/// * `value` - The Poundals input value
pub fn to_dynes(value: f64) -> f64 {
return value * 13825.4954376;
}
/// Converts the supplied Poundals value to Kilogram-force
/// # Arguments
/// * `value` - The Poundals input value
pub fn to_kilogramforce(value: f64) -> f64 {
return value / 70.93163528397;
}
}