Open rakhimov opened 7 years ago
The "unit" attribute is very confusing! We don't use it :-) It mixes to many thing. For a future format I think that we should have at least 2 attributes. One for the user point of view: the dimension (length, time, velocity, rate (1/time), mass, no dimension ...) because he needs to know what kind of value he is dealing with. See https://en.wikipedia.org/wiki/Dimensional_analysis . One for the software developer point of view: integer (long), float (double), Boolean "Unit" could be a third one. For example for a parameter with "Time" dimension we could have Hour, Minute, Year, Month, ... Everything should be in SI unit but reliability engineers don't use seconds. We could assume (for built-in laws) that parameters have default unit (hours for exponential). Anyway, these attributes have to be used only for parameter declaration, and not when they are used. So if parameter is defined with "years", the value must be multiplied by 8760 when used in the law. The problem of "years" is has that least 3 different definitions according to the industries, that why I think Unit is not mandatory in the OPEN-PSA format. Software can handle it, but write exchange format in default unit.
The "unit" attribute and values of parameters (and mission time) are underspecified, raising many questions, such as:
Let's say, we have parameter
lambda
in inverse years and assume thatmission-time
is in hours:Should there be implicit unit conversion (from years-1 to hours-1) upon the parameter use? Or mixing these parameters is an error?
What happens if at the reference site, the parameter unit is different?
Should units be checked for all expressions? Probability should have no units, so should the following fail?
Moreover, for some reason (maybe for question 2), the MEF "units" have
bool
,int
,float
, which are not units of measurement.