Calculate image size based on width

Here's how I went about the exercise from the last section.

Exercise 10: Calculate what the node image size would be, if constrained by Figure width

  • Find the total available hortizontal space in the Figure.
  • Given the size of the spacing between layers, calculate the node image width that would completely fill the available horizontal space.
  • Find the corresponding node image height.

Feel free to use my solution to the last exercise as a starting point:

Ready? Go for it.