mirror of
https://github.com/Hestia-Homes/Model.git
synced 2026-06-08 11:17:27 +00:00
implemented internal_wall_insulation cost method
This commit is contained in:
parent
89c75dcd5a
commit
4848c2f9c1
1 changed files with 213 additions and 11 deletions
|
|
@ -1,3 +1,6 @@
|
|||
import numpy as np
|
||||
|
||||
|
||||
class Costs:
|
||||
"""
|
||||
A class to calculate the costs associated with construction works,
|
||||
|
|
@ -38,17 +41,19 @@ class Costs:
|
|||
:return: A dictionary containing detailed cost breakdown.
|
||||
"""
|
||||
# Cost per m2
|
||||
material = {
|
||||
"description": "Crown Dritherm Cavity Slab 37 (Thermal conductivity 0.037 W/mK) glass fibre batt or other "
|
||||
"equal; as full or partial cavity fill; including cutting and fitting around wall ties and "
|
||||
"retaining discs",
|
||||
"depth": 75,
|
||||
"thermal_conductivity": 0.037,
|
||||
"prime_cost": 5.17,
|
||||
"material_cost": 5.62,
|
||||
"labour_cost": 2.25,
|
||||
"labour_hours": 0.13
|
||||
}
|
||||
# material = {
|
||||
# "description": "Crown Dritherm Cavity Slab 37 (Thermal conductivity 0.037 W/mK) glass fibre batt or
|
||||
# other "
|
||||
# "equal; as full or partial cavity fill; including cutting and fitting around wall ties
|
||||
# and "
|
||||
# "retaining discs",
|
||||
# "depth": 75,
|
||||
# "thermal_conductivity": 0.037,
|
||||
# "prime_cost": 5.17,
|
||||
# "material_cost": 5.62,
|
||||
# "labour_cost": 2.25,
|
||||
# "labour_hours": 0.13
|
||||
# }
|
||||
|
||||
material_cost_per_m2 = material["material_cost"]
|
||||
wall_area = self.property.insulation_wall_area
|
||||
|
|
@ -132,3 +137,200 @@ class Costs:
|
|||
"profit": profit_cost,
|
||||
"labour_hours": labour_hours
|
||||
}
|
||||
|
||||
def internal_wall_insulation(self, material, non_insulation_materials):
|
||||
"""
|
||||
Broadly speaking, the high level steps to an internal wall insulation job are the following:
|
||||
|
||||
1) Demolition: This involves removing existing wall linings, fittings, and any other obstacles.
|
||||
It's important to factor in the disposal of debris and the potential need for additional protective
|
||||
measures to ensure the safety of the work area.
|
||||
|
||||
2) Insulation Installation: This is the core part of the process where the chosen insulation material is
|
||||
applied. The choice of insulation material will depend on several factors including thermal performance,
|
||||
wall construction, and space constraints.
|
||||
|
||||
3) Vapour Barrier Installation: This is crucial for preventing moisture from penetrating the insulation,
|
||||
which can compromise its effectiveness and lead to mold growth.
|
||||
|
||||
4) Re-decoration: This involves applying plaster to the wall and then painting.
|
||||
The quality of finish here is important for both aesthetic and functional reasons.
|
||||
|
||||
5) Trim and Finishing Work: Post-insulation, tasks such as re-installing skirting boards, door frames,
|
||||
or window sills might be necessary.
|
||||
:return:
|
||||
"""
|
||||
|
||||
# Parsing the provided table into a list of dictionaries
|
||||
|
||||
# non_insulation_materials = [
|
||||
# {'type': 'iwi_wall_demolition',
|
||||
# 'description': 'Solid & Dry Lined walls: Hack of wall finishes with chipping hammer; plaster to walls.',
|
||||
# 'depth': 0.0, 'depth_unit': 0.0, 'cost_unit': 'gbp_per_m2', 'thermal_conductivity': 0.0,
|
||||
# 'thermal_conductivity_unit': 0.0, 'prime_material_cost': 0.0, 'material_cost': 0.0, 'labour_cost': 10.27,
|
||||
# 'labour_hours_per_unit': 0.33, 'plant_cost': 1.28, 'total_cost': 11.55, 'link': 'SPONs', 'Notes': 0.0},
|
||||
# {'type': 'iwi_wall_demolition',
|
||||
# 'description': 'Stud walls: Remove wall linings including battening behind; plasterboard and skim',
|
||||
# 'depth': 0.0, 'depth_unit': 0.0, 'cost_unit': 'gbp_per_m2', 'thermal_conductivity': 0.0,
|
||||
# 'thermal_conductivity_unit': 0.0, 'prime_material_cost': 0.0, 'material_cost': 0.0, 'labour_cost': 6.23,
|
||||
# 'labour_hours_per_unit': 0.2, 'plant_cost': 1.25, 'total_cost': 7.48, 'link': 'SPONs', 'Notes': 0.0},
|
||||
# {'type': 'iwi_wall_demolition',
|
||||
# 'description': 'Lathe and Plaster walls: Remove wall linings including battening behind; wood lath and '
|
||||
# 'plaster',
|
||||
# 'depth': 0.0, 'depth_unit': 0.0, 'cost_unit': 'gbp_per_m2', 'thermal_conductivity': 0.0,
|
||||
# 'thermal_conductivity_unit': 0.0, 'prime_material_cost': 0.0, 'material_cost': 0.0, 'labour_cost': 6.85,
|
||||
# 'labour_hours_per_unit': 0.22, 'plant_cost': 2.09, 'total_cost': 8.94, 'link': 'SPONs', 'Notes': 0.0},
|
||||
# {'Notes': "",
|
||||
# 'cost_unit': "",
|
||||
# 'depth': "",
|
||||
# 'depth_unit': "",
|
||||
# 'description': 'Visqueen High Performance Vapour Barrier',
|
||||
# 'labour_cost': 0.48,
|
||||
# 'labour_hours_per_unit': 0.02,
|
||||
# 'link': 'SPONs',
|
||||
# 'material_cost': 1.21,
|
||||
# 'plant_cost': 0,
|
||||
# 'prime_material_cost': 0.58,
|
||||
# 'thermal_conductivity': "",
|
||||
# 'thermal_conductivity_unit': "",
|
||||
# 'total_cost': 1.69,
|
||||
# 'type': 'iwi_vapour_barrier'},
|
||||
# {'Notes': "",
|
||||
# 'cost_unit': "",
|
||||
# 'depth': "",
|
||||
# 'depth_unit': "",
|
||||
# 'description': 'Plaster; one coat Thistle board finish or other equal; steel trowelled; 3 mm thick work '
|
||||
# 'to walls or ceilings; one coat; to plasterboard base; over 600mm wide',
|
||||
# 'labour_cost': 6.58,
|
||||
# 'labour_hours_per_unit': 0.25,
|
||||
# 'link': "",
|
||||
# 'material_cost': 0.06,
|
||||
# 'plant_cost': 0,
|
||||
# 'prime_material_cost': 0.0,
|
||||
# 'thermal_conductivity': "",
|
||||
# 'thermal_conductivity_unit': "",
|
||||
# 'total_cost': 6.64,
|
||||
# 'type': 'iwi_redecoration'},
|
||||
# {'Notes': "",
|
||||
# 'cost_unit': "",
|
||||
# 'depth': "",
|
||||
# 'depth_unit': "",
|
||||
# 'description': 'Two coats emulsion paint on plaster, over 40mm girth; 3.5m - '
|
||||
# '5m high',
|
||||
# 'labour_cost': 0.0,
|
||||
# 'labour_hours_per_unit': 0.21,
|
||||
# 'link': "",
|
||||
# 'material_cost': 0.41,
|
||||
# 'plant_cost': 0,
|
||||
# 'prime_material_cost': "",
|
||||
# 'thermal_conductivity': "",
|
||||
# 'thermal_conductivity_unit': "",
|
||||
# 'total_cost': 4.34,
|
||||
# 'type': 'iwi_redecoration'},
|
||||
# {'Notes': "",
|
||||
# 'cost_unit': "",
|
||||
# 'depth': "",
|
||||
# 'depth_unit': "",
|
||||
# 'description': 'Fitting existing softwood skirting or architrave to new '
|
||||
# 'frames; 150mm high',
|
||||
# 'labour_cost': 4.87,
|
||||
# 'labour_hours_per_unit': 0.01,
|
||||
# 'link': "",
|
||||
# 'material_cost': 4.86,
|
||||
# 'plant_cost': 0,
|
||||
# 'prime_material_cost': "",
|
||||
# 'thermal_conductivity': "",
|
||||
# 'thermal_conductivity_unit': "",
|
||||
# 'total_cost': 4.88,
|
||||
# 'type': 'iwi_finishes'}
|
||||
# ]
|
||||
#
|
||||
# material = {
|
||||
# "type": "internal_wall_insulation",
|
||||
# "description": "Ecotherm Eco-Versal PIR Insulation Board",
|
||||
# "depth": 150,
|
||||
# "depth_unit": "mm",
|
||||
# "cost_unit": "gbp_per_m2",
|
||||
# "thermal_conductivity": 0.022,
|
||||
# "thermal_conductivity_unit": "watt_per_meter_kelvin",
|
||||
# "prime_material_cost": "",
|
||||
# "material_cost": 11.68,
|
||||
# "labour_cost": 3.12,
|
||||
# "labour_hours_per_unit": 0.18,
|
||||
# "plant_cost": "",
|
||||
# "total_cost": 14.8,
|
||||
# "link": "SPONs"
|
||||
# }
|
||||
|
||||
# Cost per m2
|
||||
wall_area = self.property.insulation_wall_area
|
||||
|
||||
# Extract and check the different types of data we'll need
|
||||
demolition_data = [x for x in non_insulation_materials if x["type"] == "iwi_wall_demolition"]
|
||||
vapour_barrier_data = [x for x in non_insulation_materials if x["type"] == "iwi_vapour_barrier"]
|
||||
redecoration_data = [x for x in non_insulation_materials if x["type"] == "iwi_redecoration"]
|
||||
finishes_data = [x for x in non_insulation_materials if x["type"] == "iwi_finishes"]
|
||||
if not demolition_data:
|
||||
raise ValueError("No data found for iwi_wall_demolition")
|
||||
|
||||
if (len(vapour_barrier_data) != 1) or (len(redecoration_data) != 2) or (len(finishes_data) != 1):
|
||||
raise ValueError("Incorrect number of data entries for non-insulation materials")
|
||||
|
||||
# Break out the individual material costs
|
||||
# Since we don't know the exact wall construction, we take an average for demolition costs, since
|
||||
# the cost will depend on the type of wall construction
|
||||
demolition_material_costs = np.mean([x["material_cost"] * wall_area for x in demolition_data])
|
||||
insulation_material_costs = material["material_cost"] * wall_area
|
||||
vapour_barrier_material_costs = vapour_barrier_data[0]["material_cost"] * wall_area
|
||||
redecoration_material_costs = sum([x["material_cost"] * wall_area for x in redecoration_data])
|
||||
finishes_material_costs = finishes_data[0]["material_cost"] * wall_area
|
||||
|
||||
demolition_plant_costs = np.mean([x["plant_cost"] * wall_area for x in demolition_data])
|
||||
|
||||
demolition_labour_costs = sum([x["labour_cost"] * wall_area for x in demolition_data])
|
||||
insulation_labour_costs = material["labour_cost"] * wall_area
|
||||
vapour_barrier_labour_costs = vapour_barrier_data[0]["labour_cost"] * wall_area
|
||||
redecoration_labour_costs = sum([x["labour_cost"] * wall_area for x in redecoration_data])
|
||||
finishes_labour_costs = finishes_data[0]["labour_cost"] * wall_area
|
||||
|
||||
labour_costs = (demolition_labour_costs + insulation_labour_costs + vapour_barrier_labour_costs +
|
||||
redecoration_labour_costs + finishes_labour_costs)
|
||||
|
||||
materials_costs = (demolition_material_costs + insulation_material_costs + vapour_barrier_material_costs +
|
||||
redecoration_material_costs + finishes_material_costs)
|
||||
|
||||
subtotal_before_profit = labour_costs + materials_costs + demolition_plant_costs
|
||||
|
||||
contingency_cost = subtotal_before_profit * self.CONTINGENCY
|
||||
preliminaries_cost = subtotal_before_profit * self.PRELIMINARIES
|
||||
profit_cost = subtotal_before_profit * self.PROFIT_MARGIN
|
||||
|
||||
subtotal_before_vat = subtotal_before_profit + contingency_cost + preliminaries_cost + profit_cost
|
||||
|
||||
vat_cost = subtotal_before_vat * self.VAT_RATE
|
||||
|
||||
total_cost = subtotal_before_vat + vat_cost
|
||||
|
||||
demolition_labour_hours = sum([x["labour_hours_per_unit"] * wall_area for x in demolition_data])
|
||||
insulation_labour_hours = material["labour_hours_per_unit"] * wall_area
|
||||
vapour_barrier_labour_hours = vapour_barrier_data[0]["labour_hours_per_unit"] * wall_area
|
||||
redecoration_labour_hours = sum([x["labour_hours_per_unit"] * wall_area for x in redecoration_data])
|
||||
finishes_labour_hours = finishes_data[0]["labour_hours_per_unit"] * wall_area
|
||||
|
||||
labour_hours = (demolition_labour_hours + insulation_labour_hours + vapour_barrier_labour_hours +
|
||||
redecoration_labour_hours + finishes_labour_hours)
|
||||
|
||||
# To install internal wall insulation, a small to medium size project might be conducted by a team of 3-5 people
|
||||
labour_days = (labour_hours / 8) / 5
|
||||
|
||||
return {
|
||||
"total": total_cost,
|
||||
"subtotal": subtotal_before_vat,
|
||||
"vat": vat_cost,
|
||||
"contingency": contingency_cost,
|
||||
"preliminaries": preliminaries_cost,
|
||||
"material": materials_costs,
|
||||
"profit": profit_cost,
|
||||
"labour_hours": labour_hours,
|
||||
"labour_days": labour_days
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue