Skip to content

Commit 58b26b5

Browse files
Merge pull request #1 from MatProGo-dev/kr/feature/tableau-basic1
Simplex Solver Algo 1 Appears to Work
2 parents c07ec32 + ea29ba4 commit 58b26b5

22 files changed

Lines changed: 869 additions & 630 deletions

File tree

.github/workflows/coverage1.yml

Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
name: Code Coverage # The name of the workflow that will appear on Github
2+
3+
on:
4+
push:
5+
branches: [ main ]
6+
pull_request:
7+
# Allows you to run this workflow manually from the Actions tab
8+
workflow_dispatch:
9+
jobs:
10+
build:
11+
runs-on: ${{ matrix.os }}
12+
strategy:
13+
matrix:
14+
os: [ubuntu-latest, macos-latest, windows-latest]
15+
go: [1.23]
16+
permissions:
17+
# Give the default GITHUB_TOKEN write permission to commit and push the
18+
# added or changed files to the repository.
19+
contents: write
20+
steps:
21+
- name: Checkout repository
22+
uses: actions/checkout@v4
23+
- name: Set up Go
24+
uses: actions/setup-go@v2
25+
with:
26+
go-version: ${{ matrix.go }}
27+
28+
- name: Build project
29+
run: go install ./...
30+
31+
- name: Test Coverage
32+
run: |
33+
go test -v -cover $(go list ./... | grep -v /examples/) -coverprofile coverage.out -coverpkg ./...
34+
go tool cover -func coverage.out -o coverage_analysis.out
35+
36+
- name: Upload coverage reports to Codecov
37+
uses: codecov/codecov-action@v5
38+
env:
39+
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
40+
files: ./coverage.out

algorithms/algorithm_interface.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,5 @@ import (
66

77
type AlgorithmInterface interface {
88
// Solves the provided optimization problem.
9-
Solve(initialState AlgorithmInternalState) (problem.Solution, error)
9+
Solve(prob problem.OptimizationProblem) (problem.Solution, error)
1010
}

algorithms/algorithm_type.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,4 @@ package algorithms
22

33
type AlgorithmType int
44

5-
const TypeNaive AlgorithmType = AlgorithmType(1)
5+
const TypeNaiveTableau AlgorithmType = AlgorithmType(1)

algorithms/internal_state.go

Lines changed: 0 additions & 61 deletions
This file was deleted.

algorithms/naive.go

Lines changed: 0 additions & 206 deletions
This file was deleted.

0 commit comments

Comments
 (0)