#calculator #analog #photography #f-stop #darkroom

app fstop-print-calc

F-stop time calculator for photographic enlarging

3 unstable releases

0.3.1 Aug 29, 2024
0.3.0 Aug 28, 2024
0.2.0 Aug 26, 2024

#105 in Command line utilities

Download history 372/week @ 2024-08-26

372 downloads per month

AGPL-3.0-or-later

35KB
637 lines

Introduction

fstop-print-calc calculates times relative to a base time using fractions of f-stops.

F-stop printing

F-stop printing refers to the concept of working in fractions of an f-stop when enlarging photographic prints, rather than linear time.

The primary advantages are that test strips are created in equidistant exposure steps, and a print documented in terms of f-stops can be reproduced accurately with different lenses, apertures, and sizes.

Instead of making a test strip in linear 2s increments (5, 7, 9, 11, and 13 seconds), you might make a strip in +0, +1/3, +2/3, +1, and +4/3 stops relative to a 5s base time, which ends up being 5, 6.3, 7.9, 10, and 12.6s. With this small modification, each strip is now exactly evenly spaced in terms of exposure.

Likewise, when dodging or burning, you might indicate in your notes that a region is to be burned "+2/3rds of a stop" instead of "+5s". By using f-stops, this ends up being identical regardless of the size of the print or the lens aperture. You might print a 5x7 with a base time of 8s and burn for 2/3rds of a stop (+4.7s), and later print an 11x14 with a base time of 22s and burn for 2/3rds of a stop (+12.9s), resulting in identical exposures.

F-stop printing is nothing new, it's just a way of framing your print exposures with the same model you use when taking and developing photos.

The calculator

For the most basic usage, simply run the program with a base time and it will show +/- 3 stops in 1/3rd stop increments:

$ fstop-print-calc 16

Instead of calculating a range of values, you can calculate one specific value by specifying it in the format +X/Y or -X/Y. To see +5/3rds stop:

$ fstop-print-calc 16 -- +5/3

You can specify the number of stops to display in each direction with --stops. This will show from -5 to +5 stops from the base:

$ fstop-print-calc 16 --stops 5

You can specify the fraction of stops to use with --fraction. This will show +/- 3 stops in 1/4th stop steps:

$ fstop-print-calc 16 --fraction 4

You can specify --fraction several times, too. This shows 1/4, 1/3, and 1/2 steps combined:

$ fstop-print-calc 16 --fraction 2 --fraction 3 --fraction 4

You can output the data in CSV format:

$ fstop-print-calc 16 --csv

Or you can output an entire CSV table, with each row being offset from the next and previous row by an f-stop fraction. --stops and --fraction specify the columns while --table-stops and --table-fraction specify the rows. Generate a +/-3 stop table in 1/3rd stop increments (19x19 table), with:

$ fstop-print-calc 16 --stops 3 --csv --table-stops 3 --table-fraction 3

Instead of exporting the CSV as explicit values, you can export it as cell formulas instead with --formulas. This produces a spreadsheet with the centermost-cell as the base time, which can be changed at will and all other cells will update accordingly.

$ fstop-print-calc 16 --stops 3 --csv --table-stops 3 --table-fraction 3 --formulas

You can add --relative to any combination to display the calculations relative to the base time instead of as absolute times.

$ fstop-print-calc 16 --stops 3 --csv --table-stops 3 --table-fraction 3 --relative

You can export it as an Emacs org-mode table with --org. All of the table options are also available for org-mode: --table-stops, --table-fraction, --formulas, and --relative.

$ fstop-print-calc 16 --stops 3 --org --table-stops 3 --table-fraction 3 --formulas

The math

Fractional stops work the same as a compounding growth equation, where multiplying the base time (b) by some growth factor (x) repeatedly (N) times doubles the base time (1 stop increase). So:

b*x^N = 2*b
 => x^N = 2 [base cancels]
 => x = Nth_root(2) [Nth root of both sides]
 => x = 2^(1/N) [alternate equivalent form]

N is the fraction of a stop, and calculating for x finds an exponential growth factor.

An example for 1/3rd stop increments:

  • N is 3 (denominator of 1/3)
  • growth factor x calculated as x = 2^(1/3) = 1.25992
  • base b chosen to be 10 seconds
  • b + 1/3rd stop = 10 * 1.25992^1 = 12.599s
  • b + 2/3rd stop = 10 * 1.25992^2 = 15.874s
  • b + 3/3rd stop = 10 * 1.25992^3 = 20.000s

This works for any fraction, and for positive or negative exponents.

License (AGPL Version 3.0)

fstop-print-calc - an f-stop enlarging time calculator Copyright (C) 2024 Trevor Bentley fstop-print-calc@x.mrmekon.com

This program is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.

You should have received a copy of the GNU Affero General Public License along with this program. If not, see https://www.gnu.org/licenses/.

Dependencies

~3–15MB
~151K SLoC