Thursday, October 26, 2017

Recipe - Faering Hull

The recipe presented in the last post is of a small size. Many recipes require much more calculation than soap does (though recall that the definitions for the other recipes that go into it also required their own calculations.)

In this post I'll included screenshots of all of the calculations for the "hull, faering" recipe. I believe this is the largest recipe so far, both in terms of calculation and in number of sub-components.

A faering is a type of rowboat. Since this recipe only calculates the hull, the boat is not complete: there are no seats, no oarlocks, and no oars. Still, there's quite a lot to see, and I'm restricting myself to only those items which are directly being used in the faering hull. I'll show rivets, for example, which are made of copper, but I won't then go and show the copper recipe.

OK. Here is the faering hull itself.



You can see that the faering is composed of many shaped wooden pieces, some of them steamed, and that it is held together with lots of caulk and rivets.

The quantities of these components are calculated in the lengthy sequence starting at the top of the screenshot. It should be pretty readable. I would go into it here but I've been chipping away at this post for a week or two and I just want to get it out there.

Having seen what pieces the hull is made of, and how many of each piece we need, we can look at how each of those pieces are defined. First come the recipes for rivets and caulk, which are used to join the wooden pieces together.



Second and last, we have the wooden pieces themselves. You can see how some of them are immediately used as components in "steamed" versions, which (as seen above) are the ones which actually show up in the hull recipe proper. These steamed variants represent the woodworking technique of clamping a piece in place and then steaming it so that it will hold the shape it currently holds. This is used to achieve the curved sides of the strakes which make up the bulk of the hull.

One minor note: "semiGoods" is the name of the list of trade goods which are not considered finished products. Thus, although their prices get evaluated, they are not ordinarily displayed for sale on the trade table.


















3 comments:

  1. Wow, that's impressive !
    Did you consider using a database to store recipes and their components, then adding a UI on it to facilitate things ? More work at the beginning, far less so after.

    ReplyDelete
    Replies
    1. Vlad, I am neither here nor there on using a database. It be required if this were a real-time application - such as if it were backing a website, say.

      But it would have been slower to protoype and set up, and for the current design it wasn't necessary. And even if I had a database to store some levels of the data, I'll still have to do a lot of finicky transforms and calculations like the ones above, so I wouldn't be free of source code by a long shot.

      A GUI, on the other hand, is competely unnecessary. I can do everything related to computer programming with textual interfaces much more efficiently than with a visual one. I don't mind using the mouse where appropriate, but I wouldn't be able to achieve anything close to what I have made if it had been done through any medium other than pure coding.

      However, you have reminded me that I have done some work on visualizing recipe structures, showing how things are made of components which are in turn of made of other components, and so on. This is one area where an image can give a good intution to go along with all the text. I'll post one of those shortly.

      Delete
    2. Forgive me - I read "UI" as "GUI." You are right that a dedicated UI onto the recipe structures could have its uses, such as quickly composing existing ones into new ones, or filling in components automatically. My editor (Emacs) makes some tasks of this nature quite easy, but not all. Perhaps there are some shortcut functions I can write which would be helpful here.

      Delete