Post Reply 
WP-34S galUS-> l Precision
12-12-2016, 01:46 AM
Post: #21
RE: WP-34S galUS-> l Precision
Looks good!

Do you have commit permissions on the repository?


Pauli
Find all posts by this user
Quote this message in a reply
12-12-2016, 08:35 AM
Post: #22
RE: WP-34S galUS-> l Precision
(12-12-2016 01:46 AM)Paul Dale Wrote:  Looks good!

Do you have commit permissions on the repository?


Pauli

I believe so. I'll put in these new values as a compile-time option, turned on by default in resources.h . Is that ok?

Nigel (UK)
Find all posts by this user
Quote this message in a reply
12-12-2016, 09:02 AM
Post: #23
RE: WP-34S galUS-> l Precision
(12-12-2016 08:35 AM)Nigel (UK) Wrote:  I believe so. I'll put in these new values as a compile-time option, turned on by default in resources.h . Is that ok?

I think it better to replace the older values completely. There is no reason to have less accurate values present given the spot on citations you've provided.

We were chasing credibility with the conversions, hence the canonical NIST references. Yours are better overall IMHO.


Thanks for doing this,

Pauli
Find all posts by this user
Quote this message in a reply
12-12-2016, 11:20 PM
Post: #24
RE: WP-34S galUS-> l Precision
(12-12-2016 09:02 AM)Paul Dale Wrote:  I think it better to replace the older values completely. There is no reason to have less accurate values present given the spot on citations you've provided.

We were chasing credibility with the conversions, hence the canonical NIST references. Yours are better overall IMHO.


Thanks for doing this,

Pauli

Done now, I hope. (I was rather out of practice with svn!) I've changed compile_consts.c in the main trunk and in the three branches, and I've rebuilt the windows emulators and the calculator firmware in all but the V2.2 branch (which wouldn't compile for me).

People can find the calculator firmware here: https://sourceforge.net/p/wp34s/code/HEA...realbuild/
and in the corresponding place in the complex_mode and wp_31s branches.

I haven't rebuilt the QT emulator; I don't have the libraries installed for that.

If there are any problems I'm sure they can be fixed!

Nigel (UK)
Find all posts by this user
Quote this message in a reply
12-14-2016, 03:41 PM (This post was last modified: 12-14-2016 03:49 PM by emece67.)
Post: #25
RE: WP-34S galUS-> l Precision
Incidentally, although perhaps not a lot of people use them, the l/100 km <-> mpg conversion factors in Bit's patch must change from:

Code:
#ifdef INCLUDE_MPG_CONV
    // constant/X conversions:
    CONV("l:",    "mpgUS\016",    "LP100KM_MPGUS","235.214596754951"),    // derived: 100*L_GALUS/KM_MILE
    CONV("l:",    "mpgUK\016",    "LP100KM_MPGUK","282.480936331822"),    // derived: 100*L_GALUK/KM_MILE
#endif

to:
Code:
#ifdef INCLUDE_MPG_CONV
  // constant/X conversions:
  CONV("l:",    "mpgUS\016",    "LP100KM_MPGUS","235.2145833333333"),    // derived: 100*L_GALUS/KM_MILE
  CONV("l:",    "mpgUK\016",    "LP100KM_MPGUK","282.4809363318222"),    // derived: 100*L_GALUK/KM_MILE
#endif

Regards.
Find all posts by this user
Quote this message in a reply
12-15-2016, 04:49 PM
Post: #26
RE: WP-34S galUS-> l Precision
(12-11-2016 01:24 PM)Nigel (UK) Wrote:  I couldn't resist having a go myself! Below is my modified list of conversion factors; I've tried to be clear from where each has come. I've left the original ones in, commented out, so that the two can be compared.

So far as I know, all of these are either exact or correct to 16sf.

Code:

struct _constsml conversions[] = {
//    CONV("kg",    "lb",        "KG_LBM",    "0.4535924"),        // source: NIST
    CONV("kg",    "lb",        "KG_LBM",    "0.45359237"),        // source: NIST; exact
    
//    CONV("kg",    "stone",    "KG_STONE",    "6.3502936"),        // derived: 14 lbs to a stone
    CONV("kg",    "stone",    "KG_STONE",    "6.35029318"),        // derived: 14 lbs to a stone using exact lb; exact

//    CONV("kg",    "cwt",        "KG_CWT",    "50.8023488"),        // derived: 112lb to a long cwt
    CONV("kg",    "cwt",        "KG_CWT",    "50.80234544"),        // derived: 112lb to a long cwt using exact lb;exact

//    CONV("kg",    "s.cwt",    "KG_SHCWT",    "45.35924"),        // source: NIST hundredweight, short 100lb
    CONV("kg",    "s.cwt",    "KG_SHCWT",    "45.359237"),        // source: NIST hundredweight, short 100lb using exact lb; exact

//    CONV("g",    "oz",        "G_OZ",        "28.34952"),        // source: NIST
    CONV("g",    "oz",        "G_OZ",        "28.349523125"),        // source: NIST; 16oz to 1 lb using exact lb

//    CONV("g",    "tr.oz",    "G_TOZ",    "31.10348"),        // source: NIST
    CONV("g",    "tr.oz",    "G_TOZ",    "31.1034768"),        // source: NIST; 1 tr.oz = 480 grains; 1 lb = 7000 grains exactly; exact

    CONV("l",    "galUK",    "L_GALUK",    "4.54609"),        // source: NIST; also UK Weights and Measures act 1985; exact

//    CONV("l",    "galUS",    "L_GALUS",    "3.785412"),        // source: NIST
    CONV("l",    "galUS",    "L_GALUS",    "3.785411784"),        // source: NIST handbook 44 2017 appendix C; exact

//    CONV("l",    "cft",        "L_CUBFT",    "28.31685"),        // source: NIST
    CONV("l",    "cft",        "L_CUBFT",    "28.316846592"),        // source: 1 inch = 0.0254 m; exact

//    CONV("ml",    "flozUK",    "ML_FLOZUK",    "28.41306"),        // source: NIST oz UK fluid
    CONV("ml",    "flozUK",    "ML_FLOZUK",    "28.4130625"),        // source: 1 ukgallon = 8 pints; 1 pint = 20 flozuk; see above for exact ukgallon; exact

//    CONV("ml",    "flozUS",    "ML_FLOZUS",    "29.57353"),        // source: NIST oz US fluid
    CONV("ml",    "flozUS",    "ML_FLOZUS",    "29.5735295625"),        // source: NIST handbook 44 2017 appendix C; 1 floz = 1.8046875 in^3; exact

    CONV("cm",    "inches",    "CM_INCH",    "2.54"),        // source: NIST; exact already

    CONV("m",    "fathom",    "M_FATHOM",    "1.8288"),        // derived: 6 feet; exact

    CONV("m",    "feet",        "M_FEET",    "0.3048"),        // source: NIST; exact

//    CONV("m",    "feetUS",    "M_FEETUS",    "0.3048006096"),        // source: Wikipedia etc;
    CONV("m",    "feetUS",    "M_FEETUS",    "0.3048006096012192"),        // source: Wikipedia etc; usfoot = survey foot = 1200/3937 m exactly; number given is correct to 16sf

    CONV("m",    "yards",    "M_YARD",    "0.9144"),        // source: NIST; exact

    CONV("km",    "miles",    "KM_MILE",    "1.609344"),        // source: NIST; exact

    CONV("km",    "l.y.",        "KM_LY",    "9.4607304725808E12"),        // source: IAU (see http://www.hpmuseum.org/forum/thread-2262.html); exact

//    CONV("km",    "pc",        "KM_PC",    "3.085678E13"),        // source: NIST
    CONV("km",    "pc",        "KM_PC",    "3.085677581491367E13"),        // source: August 2015 IAU Resolution B2 defines parsec as 648000/pi AU; uses AU below; correct to 16sf

//    CONV("km",    "AU",        "KM_AU",    "149597900"),        // source: NIST, IAU 2009 gives 1.49597870700E11
    CONV("km",    "AU",        "KM_AU",    "149597870.7"),        // source: NIST, IAU 2009 gives 1.49597870700E11; value changed to this exact definition

    CONV("km",    "nmi",        "KM_NMI",    "1.852"),        // source: NIST; exact

//    CONV("m\232",    "square",    "M_SQUARE",    "9.290304"),        // derived: 
//    CONV("m\232",    "perch",    "M_PERCH",    "25.29285264"),        // derived: 

    CONV("ha",    "acres",    "HA_ACREUK",    "0.40468564224"),    // derived: 43560 square feet; exact

//    CONV("ha",    "acreUS",    "HA_ACREUS",    "0.4046873"),        // source: NIST
    CONV("ha",    "acreUS",    "HA_ACREUS",    "0.4046872609874252"),        // source: NIST; using exact definition of survey foot correct to 16sf

//    CONV("N",    "lbf",        "N_LBF",    "4.448222"),        // source: NIST
    CONV("N",    "lbf",        "N_LBF",    "4.4482216152605"),        // source: using g (standard) = 9.80665 N/kg from NIST constants and exact value for mass of 1lb; exact

//    CONV("J",    "Btu",        "J_BTU",    "1055.056"),        // source: NIST BTUit
    CONV("J",    "Btu",        "J_BTU",    "1055.05585262"),        // source: NIST; 1BTU = heat needed to raise temp of 1 lb water by 1 degF; using exact pound and calorie values gives result above

    CONV("J",    "cal",        "J_CAL",    "4.1868"),        // source: NIST calorie it (International Steam Table calorie); exact

    CONV("J",    "kWh",        "J_kWh",    "3600000"),        // source: NIST; exact

    CONV("Pa",    "atm",        "Pa_ATM",    "101325"),        // source: NIST atmosphere standard; exact

    CONV("Pa",    "bar",        "Pa_bar",    "100000"),        // source: NIST; exact

//    CONV("Pa",    "mmHg",        "Pa_mmHg",    "133.3224"),        // source: NIST cm mercury conventional
    CONV("Pa",    "mmHg",        "Pa_mmHg",    "133.322387415"),        // source: Wikipedia refers to BS 350: Part 1: 1974 - Conversion factors and tables. British Standards Institution. 1974. p. 49; exact

//    CONV("Pa",    "psi",        "Pa_psi",    "6894.757"),        // source: NIST pound-force per square inch
    CONV("Pa",    "psi",        "Pa_psi",    "6894.757293168361"),        // source: NIST pound-force per square inch; uses value for lbF above; correct to 16sf

//    CONV("Pa",    "inHg",        "Pa_inhg",    "3386.389"),        // source: NIST inch of mercury conventional
    CONV("Pa",    "inHg",        "Pa_inhg",    "3386.388640341"),        // source: NIST inch of mercury conventional; see mmHg above; exact

//    CONV("Pa",    "torr",        "Pa_torr",    "133.3224"),        // source: NIST
    CONV("Pa",    "torr",        "Pa_torr",    "133.3223684210526"),        // source: NIST; 101325/760 is exact value; corect to 16sf

//    CONV("W",    "hp(I)",    "W_HP550",    "745.6999"),        // source: NIST horsepower 550 ft . lb / s
    CONV("W",    "hp(I)",    "W_HP550",    "745.6998715822702"),        // source: NIST horsepower 550 ft . lb / s; using standard g; correct to 16sf

//    CONV("W",    "hp(M)",    "W_HP",        "735.4988"),        // source: NIST horsepower metric
    CONV("W",    "hp(M)",    "W_HP",        "735.49875"),        // source: NIST horsepower metric (lifting 75kg 1m in 1s) using standard g; exact

    CONV("W",    "hp(E)",    "W_HPe",    "746"),            // source: NIST horsepower electric; exact

//    CONV("t",    "tons",        "T_TON",    "1.016047"),        // source: NIST ton, long 2240lb
    CONV("t",    "tons",        "T_TON",    "1.0160469088"),        // source: NIST ton, long 2240lb; using exact lb; exact

//    CONV("t",    "s.tons",    "T_SHTON",    "0.9071847"),        // source: NIST ton, short 2000lb
    CONV("t",    "s.tons",    "T_SHTON",    "0.90718474"),        // source: NIST ton, short 2000lb; using exact lb; exact

    CONV(NULL, NULL, NULL, NULL)
};

Nigel (UK)

Thanks for posting this very useful info. I am glad to see the increased precision available for the WP-34S.

Interestingly, your high-precision results seem to be mostly identical to the built-in conversion factors in the HP-4X series except, of course, for the 16 digit precision. However, I have found a few discrepancies between your high-precision results and those given by the HP-50g. I am not sure on which side(s) the errors lie, but I wanted to bring the discrepancies to your attention.

The following are the HP-50's definitions which are different from the ones you listed:

Code:

1 galUK = 4.546092 l
1 flozUK = 28.413075 g (based on galUK above)
1 pc = 3.08567818585E13 km
1 l. y. = 9.46052840488E12 km
1 mm Hg = 133.322368421 Pa

This is not necessarily an exhaustive list, just the ones I noticed while poking around.

John
Find all posts by this user
Quote this message in a reply
12-15-2016, 08:09 PM
Post: #27
RE: WP-34S galUS-> l Precision
(12-15-2016 04:49 PM)John Keith Wrote:  Thanks for posting this very useful info. I am glad to see the increased precision available for the WP-34S.

Interestingly, your high-precision results seem to be mostly identical to the built-in conversion factors in the HP-4X series except, of course, for the 16 digit precision. However, I have found a few discrepancies between your high-precision results and those given by the HP-50g. I am not sure on which side(s) the errors lie, but I wanted to bring the discrepancies to your attention.

The following are the HP-50's definitions which are different from the ones you listed:

Code:

1 galUK = 4.546092 l
1 flozUK = 28.413075 g (based on galUK above)
1 pc = 3.08567818585E13 km
1 l. y. = 9.46052840488E12 km
1 mm Hg = 133.322368421 Pa

This is not necessarily an exhaustive list, just the ones I noticed while poking around.

John

The 50 uses the same definitions as the 48 series, which are quite old.
For example, the UK gallon was redefined in 1985 to match the Canadian gallon. The 50g uses the old definition, while the new one is exactly 4.54609 l, so it's been already 31 years since that definition was changed. It's time for an update.
The Parsec and light year depend on the definition of the light speed, which has remained fixed since 1983.
The mmHg depends on the standard atmosperic pressure, and the standard acceleration of gravity, which also were redefined some time ago.
Find all posts by this user
Quote this message in a reply
12-15-2016, 09:08 PM
Post: #28
RE: WP-34S galUS-> l Precision
(12-15-2016 04:49 PM)John Keith Wrote:  Thanks for posting this very useful info. I am glad to see the increased precision available for the WP-34S.

Interestingly, your high-precision results seem to be mostly identical to the built-in conversion factors in the HP-4X series except, of course, for the 16 digit precision. However, I have found a few discrepancies between your high-precision results and those given by the HP-50g. I am not sure on which side(s) the errors lie, but I wanted to bring the discrepancies to your attention.

The following are the HP-50's definitions which are different from the ones you listed:

Code:

1 galUK = 4.546092 l
1 flozUK = 28.413075 g (based on galUK above)
1 pc = 3.08567818585E13 km
1 l. y. = 9.46052840488E12 km
1 mm Hg = 133.322368421 Pa

This is not necessarily an exhaustive list, just the ones I noticed while poking around.

John

Thank you for taking the time to check the conversion factors; I've looked at them again as a result. This is what I've found.
  • galUK (including flozUK) A google search yields several sites which state that one UK gallon is 4.54609188 litres, but without (so far as I can see) giving a source. My source was the UK Weights and Measures act 1985, which is rather old. I find the same definition given in the 1995 amendment to this act, and (more authoritatively) at this NIST page where the 4.54609 value I have used is listed as being exact. In the absence of a source contradicting this, I'll leave it unchanged.
  • pc The sources on which this is based (a 2009 redefinition of the au by the International Astronomical Union (IAU), ratified in 2012, and an exact definition of the parsec as being exactly 648000/pi au, introduced by the IAU in 2015) are both more recent than the definitions in force when the HP-50g was released and so I'll leave this unchanged as well.
  • ly The issue here is the definition of "a year". I've used the Julian Year, exactly 365.25 days, in accordance with this recent document from the IAU. The HP-50g value appears to use the Mean Tropical Year, or 365.24219 days. I think that it would be reasonable to stay with the IAU definition.
  • mmHg The value given by the HP-50g is exactly 1/760 of 101325 Pa (1 standard atmosphere), which is generally known as 1 torr and not 1 mmHg. Reference 4 on the mmHg Wikipedia article is to an NPL page that (in footnote 2) lists the standard density of mercury that I've used to derive my value for mmHg. Interestingly, footnote 3 on the same page states that there is a concerted effort to remove units such as mmHg, either by excluding them from conversion tables altogether or by restricting their precision! If we aren't going to remove mmHg from the WP-34s altogether I think it should stay as it is.

So I think the values listed should stay as they are, with the possible exceptions of mmHg and inHg which (it could be argued) belong to an age that is past.

Nigel (UK)
Find all posts by this user
Quote this message in a reply
12-16-2016, 11:17 AM
Post: #29
RE: WP-34S galUS-> l Precision
(12-15-2016 09:08 PM)Nigel (UK) Wrote:  Thank you for taking the time to check the conversion factors; I've looked at them again as a result. This is what I've found.
  • galUK (including flozUK) A google search yields several sites which state that one UK gallon is 4.54609188 litres, but without (so far as I can see) giving a source. My source was the UK Weights and Measures act 1985, which is rather old. I find the same definition given in the 1995 amendment to this act, and (more authoritatively) at this NIST page where the 4.54609 value I have used is listed as being exact. In the absence of a source contradicting this, I'll leave it unchanged.
  • pc The sources on which this is based (a 2009 redefinition of the au by the International Astronomical Union (IAU), ratified in 2012, and an exact definition of the parsec as being exactly 648000/pi au, introduced by the IAU in 2015) are both more recent than the definitions in force when the HP-50g was released and so I'll leave this unchanged as well.
  • ly The issue here is the definition of "a year". I've used the Julian Year, exactly 365.25 days, in accordance with this recent document from the IAU. The HP-50g value appears to use the Mean Tropical Year, or 365.24219 days. I think that it would be reasonable to stay with the IAU definition.
  • mmHg The value given by the HP-50g is exactly 1/760 of 101325 Pa (1 standard atmosphere), which is generally known as 1 torr and not 1 mmHg. Reference 4 on the mmHg Wikipedia article is to an NPL page that (in footnote 2) lists the standard density of mercury that I've used to derive my value for mmHg. Interestingly, footnote 3 on the same page states that there is a concerted effort to remove units such as mmHg, either by excluding them from conversion tables altogether or by restricting their precision! If we aren't going to remove mmHg from the WP-34s altogether I think it should stay as it is.

So I think the values listed should stay as they are, with the possible exceptions of mmHg and inHg which (it could be argued) belong to an age that is past.

Nigel (UK)

I just double checked the definitions above and match 100% what I used in newRPL (see post #11), including the mmHg definition. So I agree these are the best definitions we have at the moment.
Find all posts by this user
Quote this message in a reply
12-16-2016, 02:46 PM (This post was last modified: 12-16-2016 07:50 PM by Vtile.)
Post: #30
RE: WP-34S galUS-> l Precision
Last time I got my blood pressure measured I think it were measured with mmHg, so it will not go anywhere. Also I wouldn't be too suprised that if it is still widely used in pressure differential measurements in laboratories, it is a functional unit not scientific. In my ears such as reduction of accuracy or removing from tables is a unresponsible act and dangerous route of thinking.

In general, SI unit system is a by far best system we (as a mankind) have had, but there is some places where it doesn't drop in nicely to real functional world around us. I kind of get itch from some non standard SI unit hatred, because they are "not accurate", when the truth is that the meter of equilibrium pile on existence in my book of reference written in the 60s is not one meter of equilibrium pile on existence measured in todays definition of meter, since the definition is changed. Even though world is still running around us and 99.999999% of all peoples related, never have given a thought at it.

Edit. Uh, sorry for the ramble.. I "miss" (only seen one old bourdon pipe type gauge with it) the Kg/cm^2 unit (and both are SI base units), made hydraulic calculations something that could be solved in the head. Big Grin
Find all posts by this user
Quote this message in a reply
12-16-2016, 08:31 PM (This post was last modified: 12-16-2016 08:36 PM by matthiaspaul.)
Post: #31
RE: WP-34S galUS-> l Precision
It's a pity that we cannot already incorporate the changes necessary for the forthcoming CODATA 2018 and the proposed "new SI"... ;-)

However, I'm sure we'll manage to update the WP 34s and newRPL when the time comes, and the HP Prime will probably be updated by HP as well. I'm a bit worried, however, if we'll manage to update the HP 50g as well in 2018... After all, there isn't even an up-to-date version of the periodic table.

Greetings,

Matthias


--
"Programs are poems for computers."
Find all posts by this user
Quote this message in a reply
12-16-2016, 10:50 PM (This post was last modified: 12-17-2016 11:13 AM by Vtile.)
Post: #32
RE: WP-34S galUS-> l Precision
(12-16-2016 08:31 PM)matthiaspaul Wrote:  It's a pity that we cannot already incorporate the changes necessary for the forthcoming CODATA 2018 and the proposed "new SI"... ;-)

However, I'm sure we'll manage to update the WP 34s and newRPL when the time comes, and the HP Prime will probably be updated by HP as well. I'm a bit worried, however, if we'll manage to update the HP 50g as well in 2018... After all, there isn't even an up-to-date version of the periodic table.

Greetings,

Matthias
Unfortunately those neat pictures do not reveal the dependency of measurement of those new reference definition umm.. matters.

I like the old ampere definition the most, infinitely long and infinitely thin lines separated by one meter and current is applied which is equivalent to one ampere, when the force between the wires reaches 2 × 10−7 Newtons (N = Kg * m/s^2). So in the past there were two wires one atom of diameter each from here to sun with distance of one meter between and somewhere on the orbit of mercury there were a Nist technician measuring the force of those lines with his or her spring forcemeter. Big Grin

The new system seems to be floating entirely, there is no ground point? By that I mean each reference is [I assume since I have not read all those reference ( I should be sleeping by now Confused )] measured by electronic devices which are calibrated with each other, how they be certain that they are not creating a system that is drifting by time since with a quick look every reference point is as the ampere definition, something atomic scale that needs a long line of accurate measurements containing the other reference to create a device to get those atomic level scales. While the references themselfs should be constants. Oh, well science. Smile It will be interesting to see is there any correlation in gold prices if and when this new system is on working state. Time to go to sleep, haha.

Edit. :Smile Brains were a bit overdone last night it seems. One thing the bureaus of measurement and units lack they have no good general level publications (assuming since there were no mention on Mikes site) about the actual measurement system and how it is maintained behind the doors etc (lack of explatatory information is general achilles heel of many sciences). Just searched through Mikes (Finnish national measurement laboratory, holds the current meter replica n.23 ) and there weren't single easy to read explanatory level publication about the work they do ( while there is plenty of good ones of practical use of their work Smile ). They organise courses in some narrow subjects, but yeah cost is hundrets of euros per head.
Find all posts by this user
Quote this message in a reply
Post Reply 




User(s) browsing this thread: 1 Guest(s)