Inventory rounding to 3 decimal points

panajana

New Member
Trial Member
Joined
Sep 2, 2018
Messages
4
Reaction score
3
Points
3
I prefer to use kilograms as a unit for my items. I noticed that subtractions from inventory are wrong in brew sessions due to the rounding to 2 decimal places. Although my items are in kg, in the recipe I often use smaller quantities. I'll give an example:
The inventory says I have 0.08 kg of Citra.
I use 25g of Citra in my recipe.
When I want to brew my recipe, it shows me that after subtraction I'll have 0.05 kg of Citra.
The correct amount would be 0.055 kg, which is not displayed because only 2 decimal places are used.

When I lose 5g here and there, it can add up very quickly to a considerable amount. I think it makes sense to use as many decimal places as you need to convert the largest unit to the smallest unit. In this case, 1 kg is 0.001 g, therefore we need 3 decimal places.

I understand you can tell me to stick to grams for everything, but I usually buy from places that have a price for kilograms and I don't want to deal with small amounts of money in the inventory.
I have no idea what you use to store your data, but adding one more decimal places in the database shouldn't be too problematic.
Thanks for considering this even though it's probably not a priority.
 
Can we also have rounding litres to the nearest 100 mL? Rounding to the 10 mL is a level or precision no one ever needs. Probably just a hangover from the same level of rounding for gallons.

For a bit more background, if I have a 12 litre batch size and I hit the calc button to update the boil volume the new batch size will be 12.01 or 11.99. Looks like some conversion to gallons and back and the rounding to two points gives the annoying new batch size.
 
Last edited:
Can we also have rounding litres to the nearest 100 mL? Rounding to the 10 mL is a level or precision no one ever needs. Probably just a hangover from the same level of rounding for gallons.

For a bit more background, if I have a 12 litre batch size and I hit the calc button to update the boil volume the new batch size will be 12.01 or 11.99. Looks like some conversion to gallons and back and the rounding to two points gives the annoying new batch size.

D1028_82_098_1200.jpg

You mean this isn't you on brewday? I'll add this to an open ticket for unit conversion
 
A bit more precision would certainly help my brewday...
 
My only concern is that I use a lot of grams/ounces. When I convert, I sure don't want 2.586 grams of something! I'm good with 2.5 or 2.6 if it must round.
 
Rethinking after Yooper's comment..

Unless this is something added as a user preference I don't see rounding to three decimal places on kilos making sense. For me it'd be better to choose grams as the recipe unit.

Some of this depends on whether the original entry is being preserved in the code or whether it's being stored in US imperial and then converted to metric for users with that preference. If it's the conversion approach then if I put in 3 kilos of pilsner I'm going to end up with 2.998 or 3.002 kilos whenever the recipe is updated. If the original entry is preserved in whatever scale it was entered I'm not too fussed.

Personally I prefer just one decimal point for any single or greater unit (so gram, kilogram or higher) and no rounding for smaller than the unit (so milligram, microgram etc.)
 
Rethinking after Yooper's comment..

Unless this is something added as a user preference I don't see rounding to three decimal places on kilos making sense. For me it'd be better to choose grams as the recipe unit.

Some of this depends on whether the original entry is being preserved in the code or whether it's being stored in US imperial and then converted to metric for users with that preference. If it's the conversion approach then if I put in 3 kilos of pilsner I'm going to end up with 2.998 or 3.002 kilos whenever the recipe is updated. If the original entry is preserved in whatever scale it was entered I'm not too fussed.

Personally I prefer just one decimal point for any single or greater unit (so gram, kilogram or higher) and no rounding for smaller than the unit (so milligram, microgram etc.)
In this case, the exact value should be stored, inventory shouldn't be rounded internally, whether that amount is displayed as 3 Kg, or 3.002 kg is a different matter.

But if you buy a new bag of hops, let's say it's 1K, and you brew a recipe and use 25grams of it. Right now your new inventory is 0.97 KG, do that a couple times and your inventory gets out of whack. Precision matters for inventory.

If this works out the way it should, your inventory should be 975 grams. Whether that's displayed as 0.975 kg, or 0.98 kg due to rounding, is a different question IMO.
 

Back
Top