Skip to content

Commit cb42f80

Browse files
committed
TerraME#16 update Dam Model
1 parent 5fa495f commit cb42f80

File tree

2 files changed

+4
-2
lines changed

2 files changed

+4
-2
lines changed

lua/Dam.lua

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
--- A water in the dam model.
22
-- @arg data.water The initial stock of water measured in m³. The initial value is 5,000,000,000.
33
-- @arg data.inFlow1 The flow of water into the dam each first season. The default is 2e9.
4+
-- @arg data.inFlow2 The flow of water into the dam each second season. The default is 1.5e9.
5+
-- @arg data.currentYear 1995.
46
-- @arg data.population The total amount of inhabitants. The default value is 1e5.
57
-- @arg data.consumePerPerson The total amount of water per inhabitant. The default value is 10.
68
-- @arg data.kWh2cubicMeters The total amount of kWh produced by cubic meters. The default value is 100.

tests/Dam.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,13 +7,13 @@ return{
77

88
model:run()
99

10-
unitTest:assertSnapshot(model.chart, "Dam-chart-1.bmp")
10+
unitTest:assertSnapshot(model.chart, "Dam-chart-1.bmp", 0.15)
1111

1212
model = Dam{countYear = true}
1313

1414
model:run()
1515

16-
unitTest:assertSnapshot(model.chart, "Dam-chart-2.bmp")
16+
unitTest:assertSnapshot(model.chart, "Dam-chart-2.bmp", 0.12)
1717
end,
1818
}
1919

0 commit comments

Comments
 (0)