Efficiency Puzzle: Wood-Powered Tree-Farm?

Started by Hans Lemurson, January 28, 2017, 06:12:39 AM

Previous topic - Next topic

Hans Lemurson

A question I have been pondering, but have not yet fully figured out the answer to, is whether it is possible to create a "Perpetual Energy Farm": A Sun Lamp powered by Fueled Generator whose wood comes from the trees being grown by said Lamp.

As we know, neither conservation of energy nor conservation of mass is an inherent property of game simulations (I'm looking at you, Dwarven Water Reactor), so there is no reason to reject this outright.  It simply comes down to the math.

-How much Power does a Sun Lamp need? (assuming it turns off during the plant rest period)
If paired with a battery, can a single Fueled Generator power a Sun Lamp all day and recharge at night?  Or does that waste too much fuel, and you should try to equalize your Lamps and Generators?
-How much wood does a Fueled Generator consume?
(20 per day, I believe)
-How long does it take for a Tree to grow?
(Wiki says Poplars are 15 days)
-How much wood per tree?
I think 40 when mature
-How dense can trees be planted around a Sun Lamp?
Looks like 25 on average, 30 max (using careful layout)

...
By my calculations, 5 Sun Lamps can be constantly powered by 8 Fueled Generators at a cost of 160 wood/day.  These lamps will provide growing area for ~125 trees.  If each tree gives 40 wood at maturity, then we are looking at a total harvest of 5,000 wood.  Dividing the yield by the daily wood consumption gives us 31.25 days/tree.  If we can Plant/Grow/Chop a tree in ~30 days, then the self-fueling tree farm starts to look like a viable possibility.

Am I missing any variables, information, or have I made any math errors here?
Mental break: playing RimWorld
Hans Lemurson is hiding in his room playing computer games.
Final straw was: Overdue projects.

Spdskatr

Calculation readjustments:

Poplar trees rest for 10 hours per day regardless of anything, so really the optimum growing period should be 15*24/14 = around 25.71 days.

So in theory this should work, but only with max efficiency and hoping that nothing goes wrong.
My mods

If 666 is evil, does that make 25.8069758011 the root of all evil?

carbon

40 wood for a Poplar sounds high. I think it's 30, but I could be wrong on that.

Heating / cooling might also be a factor in a lot of climates.

Other than that, it looks viable.

Calahan

#3
Can a Fueled Generator + Battery really keep a Sun lamp powered 24/7? I would test that personally (Edit - Just did, see below) before assuming it would, and basing calculations around it (as if it can't then everything that follows will need to be reconsidered).

Also keep in mind that yield is affected by the difficulty level. I just did a quick test and a Popular tree on Extreme yields 27 Wood, whereas at the opposite end on Peaceful it yields 39 Wood. Cutting and planting trees also takes a lot of time, so you'd likely need a lot of Pawn power to cut and plant 25 trees quick enough for it to be negligible factor. Otherwise that time would need to be accounted for in the calculations.

Overall I think it's an interesting idea, but one that fails quite badly due to opportunity cost (amongst other things). As if you are powering sun lamps to plant fields of trees just to generate power, then you are not using sun lamps to plant fields of something else, and using power generated for free* (*Wind/Solar are not strictly free, but using it here for simplicity). Pawns also have to use their time to service this system (refuelling, cutting , planting, hailing), which is time they can't use doing something else.

Plus what happens when the Fueled Generator/Battery combo breaks down? For arguments sake lets say you buy your components. If you use these sun lamp fields to grow food, cotton or drugs etc. then you can sell those things in order to raise the silver required to buy the components needed to repair the Solar/Wind/Batteries involved. But where is this silver coming from with the fields of tress? For arguments sakes, lets say this system is right on the verge of breakeven in terms of ROI (return on investment), if so then where is the excess required to pay for components?


Edit - Just did a quick test on whether a FG + Battery can power a Sun lamp.

Procedure
The test started at Day 1, Hour 5. I paused the game the moment "Resting" disappeared from the plant info panel and ordered the Sun Lamp to be turned on. And did the opposite the moment "Resting" appeared on the info panel.

Day 1, Hour 6 - Turned Sun Lamp on. Power in Battery was 694.
Day 1, Hour 19 - Turned Sun Lamp off. Power in Battery was 366.
Day 2, Hour 6, Turned Sun Lamp on. Power in Battery was 587.

So over the course of 1 Day, the battery lost 107 power. So this setup isn't self sufficient in relation to power (plus having to remember to order Pawns to flick Sun Lamps or Power Switch(es) on and off twice a day is a major pain in the backside. So regardless of the viability or not on paper, the hassle to the player of regularly flicking switches isn't something that can be ignored).

Sola

It would work, but if you're resigned to dedicating that much real estate to power, why not simply use a wind turbine with solars in the blank spots?  Less micro, more power.
Two tiers of construction jobs.  One for expensive/quality items, and one for walls/floors/etc.

https://ludeon.com/forums/index.php?topic=28669.0

Thyme

This thread is interesting for all ice sheet players, as it is too cold for any vegetation. I've thought about growing trees indoors, here's what I've come up with so far:

+using wood -> no. Simply because your turnaround is too big. 25 days growing time vs. 30 days for break even means that you get 16% out of it. For this heavy material investion, you gotta get more out of it. Heating will also eat your yield.
+trees are cold resistant (how far though?), no heating required during night. This makes it seem like an option to run this farm solely by two solar panels. During volcanic winter (light level is 80%, right?) you could power the sunlamp and six heaters. My current greenhouse uses 3, with -50°C outside.
+You will lose like three hours per day untill the panels have enough output for the sunlamp in any case. I recommend to use a time-of-day switch with a battery to automatically switch power on/off. Avoid using batteries and conduits.
+harvesting and replanting trees usually diffluences after a few harvests, the manpower need spreads out


PS: growing time is a bit more than 13 hours per day (starts at 6, ends a bit after 19)
fueled generator: 22 wood/day
all trees have the same fertility sensitivity (50%)
poplar tree: 30 wood, 15.05 days growth time (best tree)
source: ThingDefs_Plants\Plants_Wild_Temperate.xml
I'm from Austria. If I offend you, it's usually inadvertently.
Snowmen army, Chemfuel Generator, Electric Stonecutting, Smelting Tweak

Hans Lemurson

Quote from: Spdskatr on January 28, 2017, 07:16:43 AM
Calculation readjustments:

Poplar trees rest for 10 hours per day regardless of anything, so really the optimum growing period should be 15*24/14 = around 25.71 days.

So in theory this should work, but only with max efficiency and hoping that nothing goes wrong.
Ah yes, that does complicate things.  Growth time is "total growth time", not "number of days it takes".

Quote from: Calahan on January 28, 2017, 07:42:29 AMAlso keep in mind that yield is affected by the difficulty level. I just did a quick test and a Popular tree on Extreme yields 27 Wood, whereas at the opposite end on Peaceful it yields 39 Wood. Cutting and planting trees also takes a lot of time, so you'd likely need a lot of Pawn power to cut and plant 25 trees quick enough for it to be negligible factor. Otherwise that time would need to be accounted for in the calculations.

Overall I think it's an interesting idea, but one that fails quite badly due to opportunity cost (amongst other things). As if you are powering sun lamps to plant fields of trees just to generate power, then you are not using sun lamps to plant fields of something else, and using power generated for free* (*Wind/Solar are not strictly free, but using it here for simplicity). Pawns also have to use their time to service this system (refuelling, cutting , planting, hailing), which is time they can't use doing something else.
...
So regardless of the viability or not on paper, the hassle to the player of regularly flicking switches isn't something that can be ignored).
I was testing this out on Peaceful, no wonder I was getting anomalously high values for wood yields!  As a further twist though, it seems as though you can get Half of the max wood yield after a tree becomes harvestable at just 40% growth!

Yes, manually ordering flick-switching to save power is a huge pain in the butt.  I wonder if there's a mod which generates orders for switch-flicking on and off at particular times.  A sort of compromise that doesn't feel quite as cheaty as using the Time of Day switch.

Quote from: Sola on January 28, 2017, 07:54:13 AM
It would work, but if you're resigned to dedicating that much real estate to power, why not simply use a wind turbine with solars in the blank spots?  Less micro, more power.
Yeah, this fails horrible when compared to literally any other method to generate power, but It's an interesting demonstration that we CAN in fact violate conservation of energy!  With no external inputs, it is theoretically possible to generate NET POWER from roofed soil!
Mental break: playing RimWorld
Hans Lemurson is hiding in his room playing computer games.
Final straw was: Overdue projects.

Thyme

I don't understand why time-of-day switches are cheaty. We can build spacecraft in this game, yet are unable to build a programable switch?

There's no indication that the conservation of energy is implemented. Using the energy of a solar panel, you can get fiery temperatures in a room the size of said panel. Why doesn't the whole planet heat up that far? I did some math with rice in hydroponics: With 20x hydroponics and a sunlamp (exactly 3kW power drain) you can get a whopping 124 chemfuel per day, enough to fire 5.66 fueled generators (if they would accept chemfuel). For the sake of ingame realism, let's say 5, while 3 of them are needed to power the greenhouse. This means a 40% efficiency. Now that the power consumption of the refinery comes to my mind, another fueled generator is needed, but all 24 hydroponics can now be sustained, pushing the brutto outpot to 6.8 generators. 4 vs 6 generators is still 33% efficiency (+550W).

PS: Making fueled generators accept chemfuel is one line of code. I'm not suggesting to do that, but showing that it is plausible.
rice stats taken from Plant_Cultivated_Farm.xml
I'm from Austria. If I offend you, it's usually inadvertently.
Snowmen army, Chemfuel Generator, Electric Stonecutting, Smelting Tweak

Serenity

Quote
Yes, manually ordering flick-switching to save power is a huge pain in the butt.  I wonder if there's a mod which generates orders for switch-flicking on and off at particular times.
Yes:

https://github.com/Zhentar/AutoFlicker

erastudil

I tried this. I didn't do the exact math but my experience was that my wood supply slowly dwindled over time. It was fairly close though, I think it could work if you had fertile soil and double thick walls/no external walls to save energy on heat. Even if it did work, I personally would still look for an alternative source of energy due to the chore of flipping the grow room's power on and off every day. I don't think it's really viable on the maps where it would help the most (sea ice, ice sheet) due to the lack of fertile soil, and wind turbines + batteries seems like a better choice in the cases where you would consider it.

Hans Lemurson

This was my experience too.  A colony has more power draws than just the sun lamp, and its margin of return is so slim that the whole thing is basically just an expensive way of slowly burning your wood.  If you need wood in a treeless environment, you should harness the power of wind and sun more directly.

But the point of it isn't to be useful, it's to create an Over-Unity Device to violate the conservation of energy!
Mental break: playing RimWorld
Hans Lemurson is hiding in his room playing computer games.
Final straw was: Overdue projects.

b0rsuk

I think the tree cutting would be very, very slow and would cause your deadlines to slip. In the end you couldn't plant the new wave of trees on time.

Hans Lemurson

I have been using the Auto-Flicker mod, and it works great!  First thing in the morning, my pawns get out of bed and turn on all the sun lamps.

A single Generator/Battery pair can keep a Sunlamp on for about 85% normal growing time.  Perfect efficiency would be to have more generators and switch them off when the sun lamps go off, but that's a bit more micro than I'm up for.

Encouraging my pawns to plant trees in high-density patterns is a challenge.  Max density is 30 trees per lamp, but this requires a lot of micro to sustain.  Left to their own devices, you'll get 25-26 trees per lamp, but with a little trimming of the growth-zone, you can get them to plant 27-28 trees on a regular basis.

I found a minor exploit where you can plant trees in a crop field and grow both (but no crop replant).  If I plant a long-growing crop like Corn, then by the time its ready to harvest, the trees should be past the 40% threshold and yield useful wood from chopping.  Set the field to "Plant: Corn", then after it is sown, switch them to "Plant: Cecropia Trees".  ~35 tiles of crop are dug up and ~26 trees will be planted.  After the trees reach 40% or the Corn is nearing maturity (whichever comes later), switch to "Plant: Corn" again.  The trees will be chopped down, and the corn will be automatically re-sown as it is harvested.  Once sown, switch back to trees.  This will let you get double-use out of your fields, and is a simple way to manage the harvests, but it will slow down your tree planting cycle a bit.  Also it's kind of an exploit.

In any case, Chopping the trees at 40% will greatly boost your yields.  You get half the wood right then and there, and trees (like all crops) start with 5% growth.  0.5x wood in 0.35x time is better than 1x wood in 0.95x time.  Then again, more frequent chopping and replanting will also add time back into the cycle, so it might not be quite as powerful.  But I'm sure you can expect at least a 20% increase in yield by chopping at 40%-growth.  And given the slim margins we are working with, that will have a significant impact on the viability of the project (as foolish as said project is).
Mental break: playing RimWorld
Hans Lemurson is hiding in his room playing computer games.
Final straw was: Overdue projects.

Zhentar

You want to grow poplar, not cecropia. Although if poplar isn't native to the  biome, teak can be better for the blight resistance

Thyme

Have you tried using 30 1x1 growing zones? It's not that much micro once it's set up, since you can select mulitple growing zones.
I'm from Austria. If I offend you, it's usually inadvertently.
Snowmen army, Chemfuel Generator, Electric Stonecutting, Smelting Tweak