From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eric Abrahamsen Subject: Re: Using org-mode for recipes (i.e. cooking) Date: Tue, 26 Jul 2011 19:30:52 -0700 Message-ID: <87tya8v4ir.fsf@ericabrahamsen.net> References: <87k4fh2k99.wl%egh@e6h.org> <87bowgx6ou.fsf@ericabrahamsen.net> <877h7450fh.fsf@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Return-path: Received: from eggs.gnu.org ([140.186.70.92]:51001) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qlttv-0007uZ-Fb for emacs-orgmode@gnu.org; Tue, 26 Jul 2011 22:31:16 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qlttu-0001DV-AY for emacs-orgmode@gnu.org; Tue, 26 Jul 2011 22:31:11 -0400 Received: from lo.gmane.org ([80.91.229.12]:37636) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qlttt-0001DR-V8 for emacs-orgmode@gnu.org; Tue, 26 Jul 2011 22:31:10 -0400 Received: from list by lo.gmane.org with local (Exim 4.69) (envelope-from ) id 1Qltts-0003df-Lj for emacs-orgmode@gnu.org; Wed, 27 Jul 2011 04:31:08 +0200 Received: from 63.226.249.211 ([63.226.249.211]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 27 Jul 2011 04:31:08 +0200 Received: from eric by 63.226.249.211 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 27 Jul 2011 04:31:08 +0200 List-Id: "General discussions about Org-mode." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org Sender: emacs-orgmode-bounces+geo-emacs-orgmode=m.gmane.org@gnu.org To: emacs-orgmode@gnu.org On Tue, Jul 26 2011, Eric Schulte wrote: >>> First, I use org-mode to keep my recipes. Here is the format I use: >> >> [...] >> >>> and so on. I have some methods to convert units back & forth from >>> metric & narrow a recipe to ingredients only, though I think this is >>> probably not really useful. I would be happy to provide this if you >>> like. >> >> Sorry this is a little old, but if you're still willing to provide some >> functions, I'd like to see them! I'm using org mode to keep track of >> baking recipes, which are traditionally recorded as ratios of ingredient >> weights, which are then used to calculate an actual recipe based on how >> much dough you want. Any food for thought regarding programmatic >> manipulation of properties would be very welcome… >> > > +1 > > I also use Org-mode to hold recipes. Currently I just hold the > ingredients in a standard list with informally specified amounts, but I > would be interested to see other approaches and any functions for > automatic recipe manipulation. > > Incidentally I also do some baking, and while I don't currently measure > my ingredients by weight I would be interested to see (or help > brainstorm) a mechanism for reifying percentages into actual weights. Baking by weights is definitely the way to go! Much more accurate. And since ounces don't lend themselves to arithmetic, I generally go with grams. The bakers' percentage[1] says that flour is 100%, and everything else is a relative percentage of that, so the total dough comes out something like 130%. So you have a recipe like this: ** Basic Sourdough :PROPERTIES: :starter: 0.494 :flour: 1 :salt: 0.025 :water: 0.642 :END: Then I suppose it wouldn't be too much work to write a function that you call on that headline, it asks you for a total dough weight, and then calculates specific gram weights for each ingredient. I'll look into doing something like this in the next few days. In the meantime, here's the guts of what I've been using to do a similar calculation, though it wants you to know weights of pure flour and starter (and hydration of the two) ahead of time, and has salt hardcoded at 2%. #+begin_src emacs-lisp (defun my-c-s-inner (flour starter hydration starter-hydration) (let* ((starter-flour (* starter (/ starter-hydration 2))) (full-flour (+ flour (starter-flour))) (water (- (* full-flour hydration) (- starter starter-flour))) (salt (* full-flour 0.02))) (values water salt))) #+end_src I don't know enough about custom exporting to make a 3x5 card out of these things, though I suppose LaTeX could do it fairly well… Eric Footnotes: [1] http://en.wikipedia.org/wiki/Baker_percentage