logoalt Hacker News

areyousurelast Saturday at 11:24 AM3 repliesview on HN

I have wanted one general application of this idea in a spreadsheet. Specifically, I track some of my running, including speed (pace), distance, and time. Under different circumstances, I have exactly two of the three available and I want the third to be computed, but it varies which. I have found it fairly difficult to implement this kind of data entry in Google Spreadsheets and Excel, even know conceptually it's a very simple constraint "a*b=c" where I know some two variables.

As a more substantive comment: You may find the thesis "Propagation networks : a flexible and expressive substrate for computation" by Alexey Radul interesting. https://dspace.mit.edu/handle/1721.1/54635


Replies

fainpullast Saturday at 7:07 PM

You could create a table with 3 columns: distance, time, pace. Set the display format for time and pace to "Duration".

Enter these formulas:

  distance = time / pace
  time = distance * pace
  pace = time / distance
Drag fill everything down. At this point you get reference errors, but once you enter any two values (thereby overwriting the formulas in those cells), you get your result.
culilast Saturday at 9:24 PM

You just need two spreadsheet tabs. One for the "raw" input and one with a formula that either takes the input if it exists or falls back to the calculated version

davexunitlast Saturday at 9:19 PM

Came here to see if anyone mentioned propagators. That thesis is excellent. I second the recommendation.