brewmeister
v4.0.0
Published
Beer brewing simulator that allows brewers to build recipes and brew batches using the classic 13-step beer brewing process.
Readme
Brewmeister
Beer brewing simulator, using ScalaFx, ControlsFx, uPickle, Os-Lib, Ox, jDeploy and Scala 3, that allows brewers to build recipes and brew batches using the classic 13-steop beer brewing process of sanitizing, preparing, malting, milling, mashing, lautering, sparging, boiling, cooling, whirlpooling, fermenting, conditioning and kegging.
Allows a brewer to:
- define a beer recipe;
- provide batch input properties; and
- simulate the brewing of a batch via the 13-step beer brewing process.
In other words, Brewmeister can simulate the entire beer brewing process - without all the hard work, allowing a brewer to run what-if scenarios using different beer recipes and batch input properties.
Install
- Select Brewmeister
- Select a platform to download a compressed app installer.
- Decompress app installer.
- Install app by double-clicking app installer.
- Select app icon to launch app.
This install has been tested on macOS.
App
See: https://github.com/objektwerks/brewmeister/blob/main/doc/app.png
Recipes:
- Select a listed recipe to view a recipe.
- Click the Add button to build a new recipe.
- Click the Remove button to delete a selected recipe.
- Click the Brew button to simulate the brewing of a selected recipe.
Recipe:
- Click the Save button to save the selected and edited recipe.
Batches:
- Select a listed batch to view a batch.
- Click the Remove button to delete a selected batch.
Batch:
- Click the Batch tab to view batch.
- Click the Log tab to view the batch log.
- Click the Timeline tab to view the batch timeline.
Default Recipe:
- Brewmeister IPA is the default recipe. It can be removed; but it will be added at startup - if NO recipes exist.
Process
Steps used in all grain brewing. Extract brewing excludes steps 3-7.
- Sanitizing - Santize all brewing tools and containers.
- input: dirty brewing implements
- output: clean brewing implements
- Preparing - Prepare all ingredients for a brewing session.
- input - recipe
- output - recipe ingredients
- Malting - Dry and optionally roast germinated grains (barley, wheat, oats or rye) for milling.
- input - grains
- output - dry and/or roasted grains
- Milling - Crush malted grains into a grist, exposing its starches for mashing.
- input - grains
- output - crushed grains as grist
- Mashing - Transfer the grist to a mash tun with boiling water at required temp. Stir and let set for required duration, allowing for the conversion of starches into fermentable sugars - known as the wort.
- input - grist, optional adjuncts
- constraints - required mashing temp range and duration
- output - wort, pH
- Lautering - Filter out solids from the wort.
- input - wort
- output - wort
- Sparging - Pour hot water on the wort and stir to extract more sugars from the grains.
- input - wort
- output - wort, mash efficiency
- Boiling - Transfer the wort to a brew kettle and bring to a boil at required temp. Sustain boil for required duration.
- input - wort, hops, optional adjuncts
- constraints - required boiling temp range and duration
- output - wort
- Cooling - Cool the wort using a chiller, until required temp is reached.
- input - wort
- constraints - required cooling temp range
- output - wort
- Whirlpooling - Stir the wort, collecting hop solids, or trub, at the bottom-center of the kettle.
- input - wort, optional hops
- output - original gravity
- Fermenting - Transfer the wort to the primary fermenter. Then pitch the yeast into the wort, allowing for the conversion of sugars into alcohol and CO2. Ferment for required temp and duration.
- input - wort, yeast
- constraints - required fermenting temp range and duration
- output - wort, final gravity
- Conditioning - Transfer wort to a secondary fermenter. Condition for required temp and duration.
- input - wort, optional adjuncts and hops
- constraints - required conditioning temp range and duration
- output - wort, srm color
- Packaging - Bottle / Can ( carbonate with priming sugar ) or Keg ( force carbonate ) the fermented and conditioned wort. Condition for required temp and duration. Then refrigerate at required temp.
- input - wort, priming sugar or forced carbonation
- constraints - required conditioning temp range and duration
- output - beer, ibu, abv, abw, calories, brewhouse efficiency, kegging temp
Some beer recipes may require adjustments to this process.
Flow
Package / Packager / Packaged has been replaced with Keg / Kegger / Kegged for simplicity in the design.
- App -- create --> Recipe & Listener & Brewer
- App -- command --> Brewer -- handle( command )
- Sanitize --> Sanitizer -- Sanitizing & Sanitized --> Listener
- Prepare --> Preparer -- Preparing & Prepared --> Listener
- Malt --> Malter -- Malting & Malted --> Listener
- Mill --> Miller -- Milling & Milled --> Listener
- Mash --> Masher -- Mashing & Mashed --> Listener
- LogMashingTempPh --> Masher -- MashingTempPhLogged --> Listener
- Lauter --> Lauterer -- Lautering & Lautered --> Listener
- Sparge --> Sparger -- Sparing & Sparged --> Listener
- LogMashEfficiency --> Sparger -- MashEfficiencyLogged --> Listener
- Boil --> Boiler -- Boiling & Boiled --> Listener
- Cool --> Cooler -- Cooling & Cooled --> Listener
- Whirlpool --> Whirlpooler -- Whirlpooling & Whirlpooled --> Listener
- LogBoilingCoolingTempOriginalGravity --> Whirlpooler -- BoilingCoolingTempOriginalGravityLogged --> Listener
- Ferment --> Fermenter -- Fermenting & Fermented --> Listener
- LogFermentingTempFinalGravity --> Fermenter -- FermentingTempFinalGravityLogged --> Listener
- Condition --> Conditioner -- Conditioning & Conditioned --> Listener
- LogConditioningTempSrmColor --> Conditioner -- ConditioningTempSrmColorLogged --> Listener
- Keg --> Kegger -- Kegging & Kegged --> Listener
- LogKeggingTempBrewhouseEfficiency --> Kegger -- KeggingTempBrewhouseEfficiencyLogged --> Listener
- Listener -- events -> Batch
Brew Batch Input
- recipe: Recipe = Brewmeister IPA
- mashingTemp: Int = 150
- pH: Double = 5.6
- actualMashExtract: Double = 4.5
- boilingTemp: Int = 150
- coolingTemp: Int = 72
- originalGravity: Double = 1.060
- fermentingTemp: Int = 72
- finalGravity: Double = 1.012
- conditioningTemp: Int = 72
- srmColor: Int = 9
- keggingTemp: Int = 72
- appearance: Int = 3
- aroma: Int = 3
- taste: Int = 3
- actualFermentableExtract: Double = 4.5
Brew Batch Ouput
Model
- Recipe 1 --> * Grain & Hop & Adjunct & Yeast
- Brewer 1 -- brews --> * Command
- Brewer 1 -- delegates --> 1 Listener
- Listener 1 -- collects --> * Event
- Listener 1 -- builds --> * Batch
- Batch 1 --> 1 Log & Timeline
Command
- Sanitize, Prepare, Malt, Mill, Mash, LogMashingTempPh, Lauter, Sparge, LogMashEfficiency, Boil, Cool, Whirlpool, LogBoilingCoolingTempOriginalGravity, Ferment, LogFermentingTempFinalGravity, Condition, LogConditioningTempSrmColor, Keg, LogBrewhouseEfficiency
Assistant
- Sanitizer, Preparer, Malter, Miller, Masher, Lauter, Sparger, Boiler, Cooler, Whirlpooler, Fermenter, Conditioner, Kegger
Event
- Sanitized, Prepared, Malted, Milled, Mashed, MashingTempPhLogged, Lautered, Sparged, MashEfficiencyLogged, Boiled, Cooled, Whirlpooled, BoilingCoolingTempOriginalGravityLogged, Fermented, FermentingTempFinalGravityLogged, Conditioned, ConditioningTempSrmColorLogged, Kegged, BrewhouseEfficiencyLogged
Metrics
These metrics, less Plato, are captured in Batch.
- Temperature - Measured during mashing, boiling, cooling, fermentation, conditioning, kegging and refrigeration.
- Method: thermometer.
- Plato: P ~ Specific Gravity: SG See Table
- P = ( -1 * 616.868 ) + ( 1111.14 * SG ) - ( 630.272 * SG ^ 2 ) + ( 135.997 * SG ^ 3 )
- SG = 1 + ( P / ( 258.6 - ( ( P / 258.2 ) * 227.1 ) ) )
- pH - The pH balance of the mash.
- Method: pH meter.
- Original Gravity: OG - Original Gravity measures the gravity of the wort before fermentation.
- Method: hydrometer.
- Constraint: Sample must be at 20C / 68F.
- Range: 1.000 - 1.130
- Final Gravity: FG - Final Gravity measures the gravity of the wort after fermentation.
- Method: hydrometer.
- Constraint: Sample must be at 20C / 68F.
- Range: 1.000 - 1.130
- Color: SRM - Standard Reference Method (SRM) represents the color of a beer. Malt Color Units (MCU). Obtain Lovibond value from grain package.
- Method: recipe
- MCU = ( Grain Weight (lbs) ) * ( Grain Color (degrees lovibond) ) / ( Volume(gallons) )
- SRM = 1.4922 * ( MCU ^ 0.6859 )
- Range: 1 - 40
- Hop Bitterness: IBU - International Bittering Units ( IBU ) is the measure of beer bitterness that comes from boiling hops.
- Method: recipe
- Hop Weight: Actual mass of hops, excluding moisture.
- Hop Volume: Actual mass of hops, including moisture. 1 oz of dry hops equals 4-6 oz of wet hops.
- Hop Utilization % = ( Hop Alpha Acid (%) * Hop Weight (dry oz) ) / Hop Volume (fluid oz)
- IBU = ( Hop Weight (oz) * Hop Alpha Acid (%) * Hop Utilization (%) ) / 7.25
- Range: 0 - 120
- Alcohol: ABV - Measured by volume, the amount of alcohol produced in a wort during fermentation.
- Method: metrics
- ABV % = ( OG - FG ) * 131
- Range: 1.0 - 13.0 %
- Alcohol: ABW - Measured by weight, the amount of alcohol produced in a wort during fermentation.
- Method: metrics
- ABW % = ( 0.79 * ABV (%) ) / FG
- Range: 1.0 - 10.0 %
- Calories - The number of calories in a beer.
- Method: metrics
- Volume = Beer packaged container (oz)
- Alcohol Calories = ( OG - FG ) * 7.5
- Carbohydrate Calories = ( FG * 13 ) * Volume
- Calories = Alcohol Calories + Carbohydrate Calories
- Range: 10 - 600
- Mash Efficiency - Calculates the percentage of fermentable extract extracted during the mash and sparging steps.
- Method: brewer input and recipe
- Actual Mash Extract = The amount of fermentable extract collected from the mash tun.
- Potential Mash Extract = The maximum extract potential of the grain bill, calculated on the malt’s extract potential and the grain bill’s weight and volume.
- Mash Efficiency % = ( Actual Mash Extract / Potential Mash Extract ) * 100
- Range: 70 - 100 %
- Ideal: 80 - 90 %
- Brewhouse Efficiency - Accounts for inefficiencies throughout the entire brewing process.
- Method: brewer input and metrics
- Actual Fermentable Extract = The amount of fermentable extract collected from the brewhouse.
- Potential Fermentable Extract = The maximum extract potential of the grain bill, assuming 100% efficiency throughout the brewing process.
- Brewhouse Efficiency % = ( Actual Fermentable Extract / Potential Fermentable Extract ) * 100
- Range: 60 - 100 %
- Ideal: 72 - 80 %
Review
Batch contains the following review properties:
- Appearance
- Aroma
- Taste
Review ratings include: 1, 2 and 3 stars. Higher is better.
Persistence
Recipes and Batches are stored as json files here:
~/.brewmeister/store/batches | recipesLogging
Log files are stored here:
~/.brewmeister/logsBuild
sbt clean compile
Test
sbt clean test
Run
sbt run
Assembly
sbt clean test assembly copyAssemblyJar
Execute
java -jar .assembly/brewmeister-$version.jar
Deploy
- edit build.sbt ( jarVersion + version )
- edit package.json ( version + jdeploy / jar )
- edit app.conf ( about > alert > contentText )
- sbt clean test assembly copyAssemblyJar
- perform github release ( from https://github.com/objektwerks/brewmeister )
- npm login
- jdeploy publish ( to https://www.jdeploy.com/~brewmeister )
- check email for npm message
See jDeploy Docs for details.
The build.sbt tasks, createAssemblyDir and copyAssemblyJar, are not absolutely required, with assembly output copied to ./target/... by default. Also much of the old sbt assembly plugin code is no longer required. See build.sbt for details.
jDeploy Install
- Setup npm account at npmjs.com
- Install node, which installs npm, which bundles npx.
- Install jdeploy via npm - npm install -g jdeploy
- Add icon.png ( 256x256 or 512x512 ) to project root and resources/image.
- Edit jDeploy package.json as required.
- Add jdeploy and jdeploy-bundle to .gitignore
See jDeploy Docs for details.
jDeploy Issues
- jDeploy publish fails due to npm 2fa one-time password error.
- See: Github Solution
- macOS app icon not rendered correctly in Dock and Launchpad.
- Ensure app icon ( ./icon.png + ./src/main/resources/image/icon.png ) is at least 256x256. 512x512 is recommended.
- See objektwerks.ui.App stage.icons, Taskbar and Toolkit code for details.
NPM Versioning
The
build.sbtmust contain asemver 3-digitversion number. See: Npmjs Semver
NPM Registry
Brewmeister is deployed to: https://www.npmjs.com/package/brewmeister
Resources
- Doc's Brewing Glossary
- Brewing Fundamentals
- Brulosophy
- Beer XML
- Brewing Measurement Devices
- OG & FG Chart
- More Ways to Get Hoppy
- Beer Color
- Beer Advocate
This open source app, as in free beer, has been banned by Beer Advocate. Apparently promoting home brewing is forbidden. Classic corporate behavior! :)
License
Copyright (c) [2024-2025] [Objektwerks]
Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at
* http://www.apache.org/licenses/LICENSE-2.0Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.
