Skip to content

Instantly share code, notes, and snippets.

View mitchute's full-sized avatar

Matt Mitchell mitchute

  • National Renewable Energy Laboratory
  • Golden, CO
View GitHub Profile
#ifdef IMBALANCETEST
Real64 QNeighbor = 0.0;
for( DirectionCounter = NeighborBoundaryCells.l1(); DirectionCounter <= NeighborBoundaryCells.u1(); ++DirectionCounter ) {
CurDirection = NeighborBoundaryCells( DirectionCounter );
EvaluateFarfieldCharacteristics( DomainNum, cell, CurDirection, NeighborTemp, Resistance );
QNeighbor += ( NeighborTemp - RetVal ) / Resistance;
}
Real64 HeatStored = ( RetVal - cell.MyBase.Temperature_PrevTimeStep ) / Beta;
// In header
class PipingSystemDomainClass : public BaseDomainClass
{
public:
// Members
// Default Constructor
PipingSystemDomainClass(){}
// Destructor
// header.hh
class cell // cell class
{
public:
double x_loc;
};
class BaseDomainClass
{

Improve development workflows by transition all E+ utilities to C++/Python

Despite the core of E+ being fully transitioned to C++, there are a number of legacy stand-alone projects in E+ that still require developers work in FORTRAN or other languages. The following is a list of all current FORTRAN projects remaining in the E+ project.

  • Basement
  • CalcSoilSurfTemp
  • ConvertESOMTR
  • ExpandObjects
  • HVAC-Diagram
  • ParametricPreprocessor
@mitchute
mitchute / Trany.py
Last active September 19, 2016 15:34
#!/usr/bin/env python
# Attempt to automatically change the version number of all idf and imf files in a repo
# Two arguments: old version number and new version number
import sys
import shutil
import fnmatch
import os
import subprocess
Branch,
AHU2 Air Loop Main Branch, !- Name
, !- Pressure Drop Curve Name
AirLoopHVAC:OutdoorAirSystem, !- Component 1 Object Type
AHU2_OA, !- Component 1 Name
AHU2 Supply Equipment Inlet Node, !- Component 1 Inlet Node Name
AHU2_OA-AHU2_HeatC 1Node,!- Component 1 Outlet Node Name
Coil:Heating:Water, !- Component 2 Object Type
AHU2_HeatC 1, !- Component 2 Name
AHU2_OA-AHU2_HeatC 1Node,!- Component 2 Inlet Node Name
/*
* AD-DA_test.c:
* Very simple program to test the serial port. Expects
* the port to be looped back to itself
*
*/
/*
define from bcm2835.h define from Board DVK511
3.3V | | 5V -> 3.3V | | 5V
@mitchute
mitchute / results.json
Last active September 15, 2017 20:32
IDF Severe/Warnings
{
"Total Severe Count": 19,
"Total Warning Count": 1035,
"Severe Files": {
"5ZoneAirCooledWithSlab": {
"Severe Count": 5,
"Severe": [
" BuildingSurface:Detailed=\"F1-1\", invalid Outside Boundary Condition=\"GROUNDSLABPREPROCESSORPERIMETER\". The ExpandObjects program has not been run or is not in your EnergyPlus.exe folder.",
" BuildingSurface:Detailed=\"F2-1\", invalid Outside Boundary Condition=\"GROUNDSLABPREPROCESSORPERIMETER\". The ExpandObjects program has not been run or is not in your EnergyPlus.exe folder.",
" BuildingSurface:Detailed=\"F3-1\", invalid Outside Boundary Condition=\"GROUNDSLABPREPROCESSORPERIMETER\". The ExpandObjects program has not been run or is not in your EnergyPlus.exe folder.",
@mitchute
mitchute / main.py
Created September 15, 2017 14:21
pyiddidf test
from pyiddidf.idf.processor import IDFProcessor
processor = IDFProcessor()
idf_structure = processor.process_file_given_file_path('FanCoilAutoSize_MultiSpeedFan.idf')
idf_structure.write_idf('out.idf', idd_structure='Energy+.idd')
@mitchute
mitchute / usingArrayObject.for
Created September 18, 2017 14:32
GHE System IDF Configurations
GroundHeatExchanger:System,
Vertical GHE 1x4 Std,
GHLE Inlet, !- Inlet Node Name
GHLE Outlet, !- Outlet Node Name
KA Ground Temps, !- Ground Temperature Object Name
2.423, !- Ground Thermal Conductivity {W/m-K}
2.343E+06, !- Ground Thermal Heat Capacity {J/m3-K}
, !- Response Factors Object Name
GHE-1; !- GHE Object 1 Name