Template talk:Convert/Archive June 2010

New Convert/num for faster fractions
I have created a new Convert subtemplate, Convert/num, which displays the same number+fraction amounts, but uses only 2 subtemplates (rather than 4 subtemplates) to handle all types of fractions. Compare:
 * &rarr;
 * &rarr;
 * &rarr;
 * &rarr;
 * &rarr;
 * &rarr;
 * &rarr;
 * &rarr;

At some point, when the testing seems complete, we can replace the contents of {Convert/numdisp} from {Convert/num}, to bypass the 2 extra number-display subtemplates (Convert/numdisp/a and Convert/numdisp/frac1), in hundreds of articles. -Wikid77 (talk) 17:16, 29 May 2010 (UTC)
 * Interesting. It appears as though there is still a desire to retain the unicode versions when they are available (see here). Plastikspork ―Œ (talk)  01:29, 2 June 2010 (UTC)

DMS2Deg in see also section
I replaced DMS2Deg in the see also section because it substantially duplicates Decdeg and it has a bug for values between 0° and -0°59'59".&ensp;– droll  &#91;chat&#93;  22:12, 1 June 2010 (UTC)
 * P.S. Disclaimer: I created Decdeg.&ensp;– droll  &#91;chat&#93;  22:30, 1 June 2010 (UTC)

Which one is right?
Which one is right? 22 mm or 0.865 in thereverse of one the other does not entirely coincide. Peter Horn User talk 15:02, 31 May 2010 (UTC)
 * Ref: Template talk:RailGauge Peter Horn User talk 15:10, 31 May 2010 (UTC)


 * You have to compare with like with like and specify an appropriate number of digits:
 * 22 mm


 * 0.865 in
 * 0.865 in
 * 0.865 in
 * 0.865 in


 * 0.866 in
 * 0.866 in
 * 0.866 in
 * 0.866 in


 * --  Dr Greg   talk  15:28, 31 May 2010 (UTC)


 * Well, the conversion from inches to millimetres is exact in that 1 inch equals 25.4 mm EXACTLY. However, you have to keep in mind that one of the measures is the original, and one is the converted value. If you start converting back and forth, you can introduce conversion creep, so always start from the original value and only convert it into the other system ONCE. A good rule of thumb is to add one more significant figure to the converted value so you don't lose any precision.
 * 0.865 in
 * 0.866 in
 * 22 mm RockyMtnGuy (talk) 05:37, 1 June 2010 (UTC)

It is not always easy to determine what was the original value, however your explantion makes sense. Peter Horn User talk 16:02, 3 June 2010 (UTC)

Rounding these windspeed conversion to the rearest 5 mph or 5 km/h
Rounding these conversion to the rearest 5 mph or km/h 285 km/h or 175 mph/180 mph as the case may be, would that be possible? This would be to fill a technical need for the windspeed article and all the cyclone huricane and tornado articles. For a sample see Talk:Cyclone Gonu Peter Horn User talk 21:03, 5 June 2010 (UTC)
 * Possible, yes, easy ... well ... J IM ptalk·cont 09:28, 7 June 2010 (UTC)


 * The 5-unit rounding, for a single option, might be easy, but people would typically later complain they couldn't use that rounding for special options, such as when adj=on & lk=out for Imperial units. At this point, it is easier to hard-code the calculation amounts for special rounding (as, where "5" is for 5-unit rounding). In the case of cyclone, hurricane or tornado articles, they are typically forced to quote whatever figures the official weather source reports (even when they are wrong typos, in which case, the corrected value is a hand-converted amount +footnote). The rationale for denying auto-conversions (in weather articles) is because the U.S. National Weather Center (or others) often pre-rounds the data from speed in knots, causing the mph and km/h figures to not match each other, but only match the original 5-unit rounding from knots. When stating a hypothetical windspeed, search for related past storms, and perhaps use those as accurate examples of what speeds could happen in the future: again, 5-unit mph & km/h windspeeds often do not match, because speed is rounded, in 5-unit increments, from windspeed in knots. When a speed conversion is not provided in a weather source, then hand-convert the result (as: amt/5 rounded x 5). I think if Convert tried to round the storm windspeeds, there would be numerous complaints about the results, for years to come. Sometimes, finger-plus-keypad is the best technology to solve a problem. However, if there is a great need, I would create an option as "disp=5" to round by 5-unit amounts. -Wikid77 (talk) 20:53, 8 June 2010 (UTC)

Deepwater Horizon oil spill
In the article Deepwater Horizon oil spill there is a need for volume converting with multiply output values. More particularly, there is a need to show the spill and collection units in oil barrels, US gallons and cubic meters. This template converts oil barrels into US gallons and liters (e.g. 12000 to 100000 oilbbl but it does not work if liters are replaced by cubic meters. It also does not works if input value is given in US gallons. Could anybody modify this template to make these conversions possible? The discussion about units is available here. Thank you. Beagel (talk) 18:10, 8 June 2010 (UTC)
 * DONE. I have added a subtemplate to handle "USgal m3" to allow either:
 * {convert|12000| to|100000|oilbbl|USgal L||abbr=none} &rarr; 12000 to 100000 oilbbl
 * {convert|12000| to|100000|oilbbl|USgal m3||abbr=none} &rarr; 12000 to 100000 oilbbl
 * Just m3: {convert|12000|oilbbl|m3} &rarr; 12000 oilbbl
 * Thank you for suggesting that valuable combination, as: USgal/m3. We don't always think of every common possibility. The talk-page topic was archived, so I have set the new option in that oil-spill article. -Wikid77 (talk) 21:35, 8 June 2010 (UTC)

specific impulse
is there a way to do specific impulse conversion from sec to kn/kg? i don't see it in the list of supported units and it would be useful for the standard infobox on the assorted rocket pages. Seanmcd27 (talk) 17:46, 10 June 2010 (UTC)
 * Kilonewtons per kilogram is equivalent to metres per second per second so how could we convert from seconds? It seems that there are various different specific impulses, care would have to be taken not to get them confused. 17:53, 11 June 2010 (UTC)

psi & ksi
psi & ksi for: A514 steel A514 steel Peter Horn User talk 13:54, 14 May 2010 (UTC) Peter Horn User talk 23:54, 14 May 2010 (UTC)
 * 1000 psi exists.
 * 1 ksi needed.
 * Is ksi kilopounds (force) per square inch? J IM ptalk·cont 15:33, 18 May 2010 (UTC)
 * Could be either one, but see where the link ksi leads you because that is the one I'm concerned with. Peter Horn User talk 20:43, 24 May 2010 (UTC)
 * Okay  will give you kilopounds (force) per square inch. J IM ptalk·cont 23:51, 14 June 2010 (UTC)
 * Thanks, Peter Horn User talk 00:55, 15 June 2010 (UTC)

Basal area
There's a need for a conversion between the metric and English units used to express basal area– that is, between ft2 ac-1 and m2 ha-1. The conversion factors are:
 * m2 ha-1 * 4.355 = ft2 ac-1
 * ft2 ac-1 * 0.230 = m2 ha-1

As per here. I'd do it myself but I don't think I have the technical expertise. Much appreciated. Minnecologies (talk) 03:06, 13 June 2010 (UTC)


 * Done. Use the codes   and
 * 1.0000 m2/ha
 * 1.0000 sqft/acre
 * J IM ptalk·cont 23:47, 14 June 2010 (UTC)

Adjective + abbreviation
How do I use both properties? The abbreviation parameter overrides the adjective parameter. -  ʄɭoʏɗiaɲ  τ ¢  16:58, 14 June 2010 (UTC)
 * You don't. The abbreviation parameter is meant to override the adjective parameter.  This is in accordance with Wikipedia's guidelines. J IM ptalk·cont 23:22, 14 June 2010 (UTC)

Some wikipedians don't like conversion templates
Some wikis don't like conversion templates. See User talk:Peter Horn/Archive 2 for their "arguments" and "reasons". I'm all for them becase the use avoids conversion errors that often occur when the conversion is done on a calculator, or worse yet on a slide rule, outside of Wikipedia. Peter Horn User talk 20:51, 24 May 2010 (UTC)
 * A prime example for the need can be found at Talk:Ship Peter Horn User talk 15:58, 3 June 2010 (UTC)

In Banksia prionotes "longhand conversions" 265 °C (510 °F), 330 °C (625 °F), 340 °C (645 °F) and 500 °C (930 °F) compared to 265 °C, 330 °C, 340 °C and 500 °C. The latter were rolled back. However, note the dicrepencies. This is the reason why template:conversion should be used. Peter Horn User talk 01:55, 15 June 2010 (UTC)
 * You don't understand significant figures. The former conversions are much better. Hesperian 02:37, 15 June 2010 (UTC)
 * Just testing: 265 °C, 330 °C or 330 °C, 340 °C or 340 °C and 500 °C. I posted a new request at Template talk:Convert below. Peter Horn User talk 22:30, 15 June 2010 (UTC)

Different separators
I recall there being a parameter to change the standard separator from parentheses to "/", but it seems to have disappeared from the documentation. Has the feature been removed or is it just not documented? The kind of thing I'm looking for is to change the standard "1 mile (1.6 km)" to "1 mile/1.6 km" so I can use the conversion inside an already parenthesised piece of text. Astronaut (talk) 06:34, 16 June 2010 (UTC)


 * Why not use  e.g 1 mi instead? A slash looks too much like a division. J IM ptalk·cont 08:33, 16 June 2010 (UTC)


 * Ah.. I was looking for something like sep=slash and didn't notice the disp=s parameter. Anyway, it doesn't matter now; I found a way to reword without using the parenthesised text.  Thanks all the same though.  Astronaut (talk) 11:11, 16 June 2010 (UTC)

Rounding temperature conversions to the nearest 5°
Would it be possible to round temperature conversions to the nearest 5 °C or 5 °F? Peter Horn User talk 22:25, 15 June 2010 (UTC) Fixed typo. Peter Horn User talk 22:27, 15 June 2010 (UTC)


 * As a proof of concept, I created Template:Convert/LoffAoffD5SoffT which allows option "disp=5" (numeral five) to round temperature by 5-unit amounts. Some examples:
 * 100 C     &rarr; 100 C.
 * 100 C &rarr; 100 C.
 * 101 C     &rarr; 101 C.
 * 101 C &rarr; 101 C.
 * 191 C     &rarr; 191 C.
 * 191 C &rarr; 191 C.
 * 1930 C     &rarr; 1930 C.
 * 1930 C &rarr; 1930 C.
 * High temperatures ending in "0" typically round to nearest 10, so add parameter "|0" to calculate whole degrees, before rounding by 5. I understand rounding by 5 can be useful, but we need to consider the long-term complications, so this "disp=5" is a limited option to analyze the various usage issues. -Wikid77 (talk) 05:49, 18 June 2010 (UTC)

Error giving carriage return before parenthesis
Hi

there seems to be a problem with the conversion used on the Deepwater disaster page

The conversion seems to have placed a carriage return just before the closing parenthesis.

Can someone have a look and try and fix it please

Thanks...Chaosdruid (talk) 08:07, 15 June 2010 (UTC)


 * I can't see any in the page source that would do this, nor in fact on my browser they symptom you describe. Can you pin down which conversion? It could just be that a   might be needed instead of a breaking space, are you sure it is right before the closing parenthesis, or is it between the number and the unit? (Or is it a dimensionless unit?) Si Trew (talk) 07:35, 16 June 2010 (UTC)


 * Sorry, I'd already fixed it but hadn't got round to mentioning it here. J IM ptalk·cont 08:29, 16 June 2010 (UTC)


 * Treat that as a beta test then! Thanks Jimp. Si Trew (talk) 15:31, 18 June 2010 (UTC)

Route kilometres and route miles
Is it possible to convert route kilometres to route miles (and vice versa), i.e. as used on transport systems (and usually distinguished from track miles on railways with multiple tracks?) Of course the conversion is the same as for km to/from mile, is it possible to change the displayed labels? Otherwise it leads me to need rather unnatural rewording (this time in Old Rouen tramway), or of course a hand-conversion (not difficult I know). I can never get the hang of those display= options, help would be appreciated. Si Trew (talk) 12:55, 18 June 2010 (UTC)


 * Passenger miles might also fall under this. I don't know whether passenger kilometres are widely used worldwide, considering that air and sea routes are generally measured in nautical miles and this unit of measure tends to be used more within the industry than to the general public. Si Trew (talk) 15:41, 18 June 2010 (UTC)

convert kcal to kilojoules
In Ton a convert for 1 kcal, 4.184 kilojoules Peter Horn User talk 00:53, 15 June 2010 (UTC)
 * 1 kcal ... J IM ptalk·cont 10:45, 15 June 2010 (UTC)

Additional conversions
Peter Horn User talk 23:56, 16 June 2010 (UTC)
 * Ton
 * 1 Gcal
 * 1 Tcal
 * 1 Pcal
 * Ton
 * BTU/h 12000 12,000 BTU/h (3517 W)


 * BTU per hour is done ...
 * 12000 BTU/h
 * ... but I'm not so sure about the calorie units. The template has supported the megacalorie for about three years and there is currently only one transclusion. J IM ptalk·cont 08:00, 20 June 2010 (UTC)
 * For Gas compressor. This works 343 atm but 343 atm might be more appropriate. Peter Horn User talk 20:09, 28 June 2010 (UTC)

Tweeking needed
Compare 3 in, 3 in, 3 in and 3 in. Could the last one be adjusted some way to give a 75 mm output instead of 76 mm, perhaps with |disp=5| ? Peter Horn User talk 15:07, 25 June 2010 (UTC)
 * Make that the first one & the last two with |disp=5|. Peter Horn User talk 15:14, 25 June 2010 (UTC)
 * Similarly have 36 in, 36 in, 3 ft, 3 ft be giving an output of 915 mm instead of 914 mm by the use of |disp=5|. Peter Horn User talk 15:22, 25 June 2010 (UTC)


 * I have created Template:Convert/LoffAonD5Soff to support "disp=5" but only when abbr=on. This allows the following:
 * {convert|36|in|mm|sigfig=3|abbr=on|disp=5} &rarr; 36 in
 * {convert|36|in|mm|sigfig=3|abbr=on|disp=b} &rarr; 36 in
 * Full unit names required creating other subtemplates (Template:Convert/LoffAoffD5Soff to support "disp=5" when abbr=off) and for abbr=none:
 * {convert|3|in|mm|abbr=off|disp=5}  &rarr; 3 in
 * {convert|3|in|mm|abbr=none|disp=5} &rarr; 3 in
 * Perhaps there should be a parameter "inc=5" to avoid using disp=5 in the long-term redesign with more features for Convert. -Wikid77 23:04, 26 June 2010 (UTC)
 * Whatever gets the job done..."inc=5" (increments) seems OK, including temperature converts. Peter Horn User talk 20:13, 28 June 2010 (UTC)


 * Peter, after our previous exchanges on the subject of rounding in 5's, I am pleased to see you are following up with a request here. I think it may help if I explain why it would be a good idea. I have two reasons, roughly appropriate precision and reader comfort. For example, where an item is being described in inches and fractions but its nature is such that the measurement is fairly imprecise, a conversion to the nearest 1 mm may give an inappropriate impression of precision, while the nearest 10 mm could be too vague. Think, for example, of a rough-sawn piece of wood, or a cocktail onion. Giving the conversion to the nearest 5 mm would often give the right feel. More subtly, an appropriate degree of precision in conversion minimises the tiny interruption in the flow of thought caused by having to interpret it. In the right context, say, '25 mm' or '65mm' is 'got' more quickly than '23 mm' or '67 mm'. Where the context makes both 1x and 10x seem out of place, the discomfiture caused by the disjunction is the greater, and could often be alleviated by a half-decade rounding option. I am not sure how far this effect extends: I see '1650 mm' as easier than '1630 mm', but not much, while '20.4 mm' seems no more time consuming to grasp than '20.5'. I am also not sure of the extent to which I am describing a personal or a common response. The style manual does not seem to advise on appropriate numerical precision (I don't have a spare month to read the archive). Globbet (talk) 22:21, 29 June 2010 (UTC)