NatLabRockies / NatLabRockies/OpenStudio

Consider checking TableLookup number of independent variables when setting a Curve where the reference is <Uni/Bi/.../Quint>VariateFunctions

Open
#4,982 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Enhancement Request Triage
Dominant language
C++
Stars
646
Forks
237
Avg merge
3d 11h
Merged PRs (30d)
10

Description

Enhancement Request

Consider checking Curve, but mostly TableLookup object dimensions when setting a Curve where the reference is <Uni/Bi/.../Quint>VariateFunctions

Note: The individual Curve objects, except TableLookup, are already checked for via the references, because for eg OS:Curve:Biquadratic has \reference BivariateFunctions and \reference AllCurves

Detailed Description

See details on https://github.com/NREL/OpenStudio/pull/4950#discussion_r1309817457

Possible Implementation

Add setCurve(const Curve& curve) method that checks the IDD choice references and enforces that the Curve object being passed has the right amount of variables.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start with the Curve and TableLookup APIs, especially the proposed setCurve(const Curve& curve) entry point, and read the discussion linked from PR #4950. Done means checking that TableLookup dimensions match the referenced Uni/Bi/.../QuintVariateFunctions choice and enforcing the valid variable count.

Written by the indexing model from the issue text.

Assessment

Tech stack
cpp
Domain
backend-api-design
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
38/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.