A powerful command line tool for performing stoichiometry calculations on checmicals and chemical equations.

Overview

Stoichiometry

Stoichiometry is a powerful command line tool for preforming stoichiometry chemicals and chemical equations. Its subcommands are listed below.

React

The React subcommand performs limiting factor calculations on a chemical equation to calculate the exact amounts of reactants required and products produced. It takes one argument, equation, which is a textual representation of the balanced chemical reaction in the form

Na2(CO3) + CaCl2 -> Ca(CO3) + 2NaCl 

Where Na2(CO3) and CaCl2 are reactants, and Ca(CO3) and NaCl are products.

You must also provide at least one target argument. When targetting an amount of either a reactant or product, you use the -r and -p options respectively, adding either a ? (unknown amount) or a number representing the targeted number of grams for each reactant/product. This example react command calculates the required amounts of sodium carbonate and calcium chloride to produce 2 grams of calcium carbonate:

$ stoic react "Na2(CO3) + CaCl2 -> Ca(CO3) + 2NaCl" -p 2 ?
Reaction: Na2(CO3) + CaCl2 -> Ca(CO3) + 2NaCl
Reactants:
Na2(CO3) required: 2.117920887633085g
CaCl2 required: 2.2176519487163096g
Products:
Ca(CO3) produced: 2.0g
NaCl produced: 2.335572836349394g

The -v flag enables verbose output, which prints the detailed molar mass calculations for each compound and the limiting reaction calculation. Here is the output of the previous example with the verbose flag enabled:

$ stoic react "Na2(CO3) + CaCl2 -> Ca(CO3) + 2NaCl" -p 2 ? -v
Reaction: Na2(CO3) + CaCl2 -> Ca(CO3) + 2NaCl
Molar mass calculations:
Molar mass of Na2(CO3) = 2x22.989769282 + (12.011 + 3x15.999) = 105.987538564 g/mol
Molar mass of CaCl2 = 40.0784 + 2x35.45 = 110.97840000000001 g/mol
Molar mass of Ca(CO3) = 40.0784 + (12.011 + 3x15.999) = 100.0864 g/mol
Molar mass of NaCl = 22.989769282 + 35.45 = 58.439769282 g/mol
Limiting factor calculation:
Number of reactions to produce 0.019982734917031685 mol of Ca(CO3): 0.019982734917031685
Limiting factor: Ca(CO3) (0.019982734917031685 reactions occurring)
0.019982734917031685 mol Na2(CO3) used
0.019982734917031685 mol CaCl2 used
0.019982734917031685 mol Ca(CO3) produced
0.03996546983406337 mol NaCl produced
Reactants:
Na2(CO3) required: 2.117920887633085g
CaCl2 required: 2.2176519487163096g
Products:
Ca(CO3) produced: 2.0g
NaCl produced: 2.335572836349394g

The -o option changes the output units, if you want to view the reactant/product amounts in another format. Supported formats are grams, milligrams, and moles.

You might also like...
Command Line Tool for interacting with MachO binaries on OSX/iOS

inject inject is a tool which interfaces with MachO binaries in order to insert load commands. Below is its help. ➜ ./inject -h OVERVIEW: inject v1.0.

CookCLI is provided as a command-line tool to make Cook recipe management easier

CookCLI is provided as a command-line tool to make Cook recipe management easier, and enable automation and scripting workflows for the CookLa

A Mac command-line tool that automatically downloads macOS Installers / Firmwares.
A Mac command-line tool that automatically downloads macOS Installers / Firmwares.

MIST - macOS Installer Super Tool A Mac command-line tool that automatically downloads macOS Installers / Firmwares: Features List all available macOS

macOS command line tool to return the available disk space on APFS volumes

diskspace Returns available disk space With the various APFS features the value for free disk space returned from tools such as du or df will not be a

A command-line tool to generate a JSON-list of all used SPM-dependencies of an Xcode-project.

SwiftPackageList A command-line tool to generate a JSON-list of all used SPM-dependencies of an Xcode-project. This includes all the Package.resolved

A command-line tool to sort Xcode's `.xcodeproj` file.

XcodeProjSorter A command-line tool to sort Xcode's .xcodeproj file. It sorts following sessions: PBXGroup PBXResourcesBuildPhase PBXSourcesBuildPhase

Josephus - A command line tool to solve Josephus problem in Swift
Josephus - A command line tool to solve Josephus problem in Swift

josephus A command line tool to solve Josephus problem in Swift

Mac App Store: Embedding a Command Line tool using paths as arguments

Mac App Store: Embedding a Command Line tool using paths as arguments Code snippets to embed a Command Line tool using paths as arguments on the Mac A

Compose beautiful command line interfaces in Swift
Compose beautiful command line interfaces in Swift

Commander is a small Swift framework allowing you to craft beautiful command line interfaces in a composable way. Usage Simple Hello World i

Comments
  • Use in other applications

    Use in other applications

    Hi thegail, fellow developer here. Was wondering whether you would be ok with my usage of this wonderful tool in my app https://github.com/mdnich/SciTool

    You would be of course attributed. Thank you so much, MDNich

    opened by MDNich 1
Releases(v0.1.0-alpha)
  • v0.1.0-alpha(Nov 17, 2021)

    Alpha version 0.1.0 implements the react subcommand, which calculates the amounts of reactants required and products produced in a chemical reaction. This includes the equation parser, molar mass calculations, limiting factor calculations, and command line argument parsing.

    Source code(tar.gz)
    Source code(zip)
    stoic(3.52 MB)
Owner
null
iOS command-line tool that allows searching and downloading ipa files from the iOS App Store

ipatool for iOS This is a port of Majd Alfhaily's ipatool adapted to run on iOS Build / Installation To build this, make sure you have AppSync install

dan 21 Sep 13, 2022
The best command-line tool to install and switch between multiple versions of Xcode.

The best command-line tool to install and switch between multiple versions of Xcode.

Robots and Pencils 2.3k Jan 9, 2023
A command line tool to easily install and browse Xcode templates

?? XTrail A command line tool to easily install and browse Xcode templates. Usage The general invocation syntax for xtrail is as follows: xtrail <subc

Shogo Sakaue 3 Dec 16, 2021
A command line tool to parse pricing from a pdf and generate an updated csv file for House Call Pro

A command line tool to parse pricing from a pdf and generate an updated csv file for House Call Pro

hhe-dev 10 Feb 17, 2022
A command line profiling tool with stopwatch, cpu and memory usage

timeui A command line profiling tool with stopwatch, cpu and memory usage. Usage ./timeui path/to/app-to-profile runs the stopwatch and signpost regio

Marin Todorov 107 Dec 10, 2022
RsyncOSX and RsyncUI are GUI´s on the Apple macOS plattform for the command line tool rsync

Hi there ?? RsyncOSX and RsyncUI are GUI´s on the Apple macOS plattform for the command line tool rsync. It is rsync which executes the synchronize ta

Thomas Evensen 1.1k Dec 23, 2022
A command line tool that calls your Xcode Test Plan and creates screenshots of your app automatically.

ShotPlan (WIP) A command line tool that calls your Xcode Test Plan and creates screenshots of your app automatically. ShotPlan will also take care of

Devran Cosmo Uenal 6 Jul 21, 2022
A Mac command-line tool that generates kick-ass Jamf Pro reports.

KMART - Kick-Ass Mac Admin Reporting Tool A command-line utility generating kick-ass Jamf Pro reports: Features Reporting on the following Jamf Pro ob

Nindi Gill 86 Dec 15, 2022
A nifty command-line tool to customize macOS icons

iconset A nifty command line tool to manage macOS icons iconset is a new command line tool for macOS that allows you to change icons for macOS apps (e

aarnav tale 32 Nov 17, 2022
🕳 A simple command line tool to punch hole to reduce disk usage on APFS volume for such as a raw disk image.

HolePunch NAME holepunch -- A simple command line tool to punch hole to reduce disk usage on APFS volume for such as a raw disk image. SYNOPSIS holepu

Yoshimasa Niwa 15 Nov 24, 2022