Temperature Conversions
Convert between three temperature scales commonly used in science and daily life.Supported Units
Celsius (°C)
Metric standard, water freezes at 0°C
Fahrenheit (°F)
US customary, water freezes at 32°F
Kelvin (K)
Absolute scale, zero is absolute zero
Conversion Formulas
The backend uses a base conversion strategy where all temperatures are first converted to Celsius, then to the target unit:- To Celsius
- From Celsius
From Fahrenheit:From Kelvin:
From server.py:34-39
Examples
| Input | Output | Use Case |
|---|---|---|
| 0°C | 32°F | Freezing point of water |
| 100°C | 212°F | Boiling point of water |
| 37°C | 98.6°F | Human body temperature |
| -40°C | -40°F | Temperature scales intersect |
| 0 K | -273.15°C | Absolute zero |
Length Conversions
Convert between metric and imperial length measurements.Supported Units
m (Meters)
Base SI unit for length
km (Kilometers)
1 km = 1000 meters
mi (Miles)
US/UK imperial mile
ft (Feet)
US customary unit
Conversion Formulas
All lengths are converted to meters as the base unit, then to the target:From server.py:58-61
Precise Conversion Factors
| Unit | Meters Equivalent |
|---|---|
| 1 meter (m) | 1.0 m |
| 1 kilometer (km) | 1,000 m |
| 1 mile (mi) | 1,609.344 m |
| 1 foot (ft) | 0.3048 m |
Examples
| Input | Output | Use Case |
|---|---|---|
| 1 km | 0.621371 mi | Distance conversion |
| 1 mi | 5,280 ft | Mile to feet |
| 100 m | 328.084 ft | Track and field |
| 1 ft | 0.3048 m | Construction measurements |
Weight Conversions
Convert between metric and imperial weight/mass measurements.Supported Units
kg (Kilograms)
Base SI unit for mass
lb (Pounds)
US customary weight unit
g (Grams)
1 g = 0.001 kg
Conversion Formulas
All weights are converted to kilograms as the base unit, then to the target:From server.py:74-77
Precise Conversion Factors
| Unit | Kilograms Equivalent |
|---|---|
| 1 kilogram (kg) | 1.0 kg |
| 1 pound (lb) | 0.453592 kg |
| 1 gram (g) | 0.001 kg |
Examples
| Input | Output | Use Case |
|---|---|---|
| 1 kg | 2.20462 lb | Weight conversion |
| 1 lb | 453.592 g | Cooking measurements |
| 1000 g | 1 kg | Metric system |
| 150 lb | 68.0389 kg | Body weight |
Velocity Conversions
Convert between different speed measurement systems.Supported Units
km/h
Kilometers per hour (metric)
mph
Miles per hour (imperial)
m/s
Meters per second (SI base)
Conversion Formulas
All velocities are converted to meters per second (m/s) as the base unit, then to the target:From server.py:90-93
Precise Conversion Factors
| Unit | Meters/Second Equivalent |
|---|---|
| 1 m/s | 1.0 m/s |
| 1 km/h | 0.277778 m/s (1/3.6) |
| 1 mph | 0.44704 m/s |
Examples
| Input | Output | Use Case |
|---|---|---|
| 100 km/h | 62.1371 mph | Highway speed limits |
| 60 mph | 96.5606 km/h | Speed limit conversion |
| 10 m/s | 36 km/h | Physics problems |
| 100 km/h | 27.7778 m/s | Scientific calculations |
Implementation Details
Backend Architecture
All conversions are performed by the ICE backend server (server.py) which implements the ConversorUnidades interface:
From server.py:14-93
Unit Validation
The server validates all units before performing conversions:From server.py:114-128
Precision and Rounding
Available Units Query
The server provides a method to query available units for any category:From server.py:95-112