Questions tagged [unit-conversion]

Unit conversion is the process of applying an arithmetic transformation (usually multiplying/dividing or adding/subtracting) using a conversion factor to convert one textual representation of a quantity, based on one unit, to another.

Unit conversion is the process of applying an arithmetic transformation (usually multiplying/dividing or adding/subtracting) using a conversion factor to convert one textual representation of a quantity, based on one unit, to another.

Dimensional analysis is a related process that can assist in identifying the conversion(s) to be performed.

91 questions
0
votes
1 answer

How to change 2nd pickerview component based on 1st component selection in a pickerview?

I am working on an unit converter app. Once I input numbers to UITextLabel, pickerview will open automatically and upon choosing an option such as Feet, Yards, etc, the result will be displayed. Now, I am looking to extend this functionality for…
0
votes
1 answer

boost::posix_time::ptime from const char* "substring"

EDIT: Actually, while we are at it, I need to do the same thing for a double as well - I have something NNNDD in the middle of a const char*, where the N's are the whole part and the D's are the decimal (so in 123.45 would appear as a const char* to…
Argent
  • 795
  • 2
  • 7
  • 25
0
votes
1 answer

Energy Conversion

I have taken this code from an example but I don't know how to calculate the value to Base Unit. This is the code for converting energy: public enum U_EnergyConverter implements UnitConverter { energy_calories { @Override public double…
swis.m
  • 61
  • 1
  • 8
0
votes
1 answer

Millimeters to Pixels to Buffered Image then print it. Does not have the original size

So basically my problem is that I basicly create some objects which are filled in as millimeters then converted to pixels using (MM * DPI) / MMPI. This is stored in a buffered Image which I then print, the only problem is, that the image is not the…
Maarten
  • 635
  • 1
  • 9
  • 29
0
votes
1 answer

How to Convert DataTable Column values from One Unit to another in C#?

I have a DataTable with some Column values filled with. I want to Convert the Column values from one unit to another. DataTable Columns(Name,Height,Width) Eg:Inch to Meter, Meter to Centimeter etc. Id UnitName 1 Inches 2 Millimeters 3 …
SHEKHAR SHETE
  • 5,964
  • 15
  • 85
  • 143
0
votes
2 answers

Javascript: unit of measure conversion library?

Is there are reputable and comprehensive unit conversion Javascript library? I do not want any libraries that makes AJAX calls to WolframAlpha or Google but something that does the calculation locally.
pathikrit
  • 32,469
  • 37
  • 142
  • 221
0
votes
1 answer

How to find out how many units across the screen plane in OpenGL

How would one get the relative size of the viewing plane in opengl's own units? I need to find out the width and height in "opengl units". Is there a function which will retrieve this information? I assume that one unit (let us say 1.0f) in Z would…
-1
votes
3 answers

what is wrong here? Unit converter

it keeps on going into a continues loop not sure why!! this is not an assignment, just Practice, i'm trying to learn, I want to make a unit converter but im not sure if this is the beast way, if you have a better idea please feel free. /// Write a…
3amasha
  • 1
  • 3
-1
votes
1 answer

Conversion Formulas Metric to English

Everywhere I look, I see the following as the list of formulas for converting metric to SI: C * 1.8 + 32 = F Km / 1.609344 = Mi mm / 25.4 = in m/s * 2.236936 = mph However, the first and the 3rd do not seem very precise. Are there more precise…
Chthonic One
  • 213
  • 3
  • 11
-1
votes
1 answer

length converter android studio

I am trying to make a length converter app and my confusion is how do I get my work done to convert from one unit to another unit using two spinners and a calculate button? The issue I have is that I cannot figure out how to convert the unit in the…
kay19
  • 1
  • 1
  • 1
-1
votes
1 answer

Android unit converter... too many equations

I am creating a unit converter for Android that uses buttons (to select the type of unit) and spinners (to select the unit) but I have ran into a problem. There are too many possible equations. If you have ten units in each spinner for all the unit…
Eklassen
  • 13
  • 1
  • 6
-1
votes
1 answer

How to convert from grams to lbs in C#

My question is how do I convert from kg to pound and oz? I know that 1kg=1000gm and 2 lb 3.274 oz (1 lb = 16 oz) I will read a file containing: weight 3000 gm for A and for B the weight is 90 kg So the result for 3000 kg will be weight 188 lb and…
sara white
  • 101
  • 1
  • 2
  • 6
-2
votes
1 answer

Converting between WGS84 degrees latitude/longitude and meters?

So, I am doing some work with data from an INS unit, in order to calculate the errors in its readings by integrating its velocity data over time to get a change in position, and then comparing that to its actual recorded change in position. The…
nick012000
  • 159
  • 2
  • 12
-2
votes
2 answers

Any way to do "real-time" unit conversion in web application

I want to build a website that allows the user to convert Hz to bpm (note however that my question concerns all sort of unit conversion). I am using PHP and am hosting my website on Apache. So, I was wondering if it was possible to "bind" an input…
Gaboik1
  • 353
  • 3
  • 15
-2
votes
1 answer

How to Convert Inch unit to Fraction unit in c#?

I have created an application in WPF which convert Imperial to Metric and Metric to Imperial units. I have data in Inch unit now this value i want to convert it in Fraction unit. I have searched but not got any specific formula to implement. Any…
SHEKHAR SHETE
  • 5,964
  • 15
  • 85
  • 143