Unit definitions and conversion functions.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
integer, | public, | parameter | :: | UNIT_NONE | = | 0 |
No unit. |
integer, | public, | parameter | :: | UNIT_RAD | = | 1 |
Radiants [rad]. |
integer, | public, | parameter | :: | UNIT_GON | = | 2 |
Gradians [gon]. |
integer, | public, | parameter | :: | UNIT_DEG | = | 3 |
Degrees [deg]. |
Generic unit type.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
real(kind=r8), | public | :: | value | = | 0.0_r8 |
Value. |
|
integer, | public | :: | type | = | UNIT_NONE |
Unit of value. |
|
integer, | public | :: | error | = | E_NONE |
Convert error. |
Angle type.
Type | Visibility | Attributes | Name | Initial | |||
---|---|---|---|---|---|---|---|
real(kind=r8), | public | :: | value | = | 0.0_r8 |
Value. |
|
integer, | public | :: | type | = | UNIT_NONE |
Unit of value. |
|
integer, | public | :: | error | = | E_NONE |
Convert error. |
Converts angle to degrees.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(angle_type), | intent(in) | :: | a |
Input angle. |
Output angle [deg].
Converts angle to gradians.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(angle_type), | intent(in) | :: | a |
Input angle. |
Output angle [gon].
Converts angle to radiants.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(angle_type), | intent(in) | :: | a |
Input angle. |
Output angle [rad].
Returns unit type.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(unit_type), | intent(in) | :: | a |
Angle type. |
Unit of angle.
Returns unit value.
Type | Intent | Optional | Attributes | Name | ||
---|---|---|---|---|---|---|
type(unit_type), | intent(in) | :: | a |
Angle type. |
Unit of angle.