Skip to content
This repository has been archived by the owner on May 15, 2024. It is now read-only.

Commit

Permalink
Reorganization and code cleanup
Browse files Browse the repository at this point in the history
  • Loading branch information
deslaughter committed Dec 29, 2023
1 parent 75c0364 commit 2fdb5f6
Show file tree
Hide file tree
Showing 42 changed files with 1,941 additions and 1,251 deletions.
12 changes: 11 additions & 1 deletion analysis.go
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,16 @@ func NewAnalysis() *Analysis {
}
}

func (an *Analysis) Calculate() error {
for i := range an.Cases {
an.Cases[i].ID = i + 1
if err := an.Cases[i].Calculate(); err != nil {
return err
}
}
return nil
}

type Case struct {
ID int `json:"ID"`
Name string `json:"Name"`
Expand Down Expand Up @@ -183,7 +193,7 @@ type AeroStructure struct {
OperatingPoints []Condition `json:"OperatingPoints"`
}

func (an *Analysis) Calculate() error {
func (an *Analysis) CalculateCases() error {

for i := range an.Cases {
an.Cases[i].ID = i + 1
Expand Down
Loading

0 comments on commit 2fdb5f6

Please sign in to comment.