Skip to content

mbcoalson/engineering_calcs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Engineering Tools with SmolAgents

This repository provides a collection of modular engineering calculation tools designed for building energy systems. The tools focus on HVAC performance, energy cost estimation, and retrofit savings analyses. Originally developed to work with the SmolAgents framework, these files now function as standalone scripts or can be integrated with agent frameworks for automated analysis.


Overview

This project includes multiple calculation modules for:

  • Boiler Plant Energy Use & Savings
    Estimate boiler input/output energy, efficiency, and potential savings through improved operations.
  • Chilled Water Energy Analysis
    Process Excel/CSV datasets from AHUs to calculate cooling energy usage and to produce unit-converted summaries.
  • VFD Energy Savings
    Two alternative approaches:
    • Fallback Estimation: Uses predefined fan speed profiles and schedules to estimate energy and demand costs.
    • Data-Driven Approach (Test): Leverages trend data to compute instantaneous fan power and aggregate energy consumption.
  • VAV DDC Replacement Savings
    Estimate annual energy cost savings achievable by replacing legacy VAV systems with DDC-controlled units that improve static pressure and supply air temperature control.

In addition, several Gradio demo scripts (e.g. app.py, app_og.py) provide interactive web interfaces for live testing and demonstrations.


Project Structure

Key files in this folder include:

  • boiler_plant_energy_template.py
    Contains boiler energy input/output calculations, pump energy estimations, and cost computations based on user-specified scenarios.

  • calculate_chilled_water_energy.py
    Reads AHU data from Excel/CSV files, cleans and standardizes column names, computes delta T, and calculates total cooling energy (in BTU, ton-hours, and kWh). It also saves results to new Excel files.

  • vfd_energy_estimate_fallback.py
    Provides a fallback estimation method to calculate fan energy/demand costs using predefined fan speed profiles (e.g. by building type).

  • vfd_tools_test.py
    Includes alternative energy savings calculations based on VFD trend data from CSV files.
    Note: May still contain references to legacy dependencies such as smolagents.

  • vav_ddc_replacement_energy_savings.py
    Estimates energy cost savings from replacing legacy VAV systems with improved DDC-controlled units. It calculates the combined savings from static pressure and supply air temperature improvements.

  • Gradio Demo Scripts (app.py, app_og.py)
    Provide web-based interfaces for interacting with the aforementioned calculation tools.

  • Additional Files & Documents
    Documentation files (README.md, tool-specific markdown files), workbooks, and related resources that aid in the understanding and deployment of these tools.


Getting Started

  1. Clone the Repository and Navigate to the Directory

    git clone https://github.com/mbcoalson/engineering_calcs.git
    cd engineering_calcs
  2. Set Up Your Virtual Environment

    python -m venv venv

    Activate the virtual environment:

    • On Windows:
      .\venv\Scripts\Activate.ps1
    • On macOS/Linux:
      source venv/bin/activate
  3. Install Dependencies Install the required packages using:

    pip install -r requirements.txt
  4. Run a Demo For example, to launch the Gradio interface demo:

    python app_og.py

Usage

  • For Boiler Plant Calculations:
    Edit the input parameters in boiler_plant_energy_template.py (e.g., boiler ratings, pump specs) and run the script to generate a detailed energy and savings report.

  • For Chilled Water Energy Analysis:
    Update the file path in calculate_chilled_water_energy.py to point to your AHU data file, then run the script. The output Excel file will be saved with summarized energy metrics.

  • For VFD and VAV Calculations:
    Use the provided functions and demo scripts to estimate energy cost savings. The output is typically printed to the console or provided via the Gradio interface.

  • Integration with SmolAgents:
    The tools were originally designed to be compatible with SmolAgents frameworks (using the @tool decorator). See the respective files and the examples in this README for guidance on integrating with agents.


Future Work

  • Refine Data-Driven Models:
    Further testing and validation of the VFD energy savings methods.

  • Expand Agent Integration:
    Enhance compatibility with LLM-driven analytics for automated decision support.

  • Documentation Enhancements:
    More detailed usage examples and case studies.


License

This project is licensed under the MIT License.


Author

Created by mbcoalson.

About

Engineering Tools with SmolAgents is a collection of modular calculation tools aimed at analyzing and optimizing building energy systems. Originally designed to integrate with the SmolAgents, these tools currently function as standalone modules. SmolAgents update is intended in future development.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors