• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Open-Sn / opensn / 18300593117

06 Oct 2025 10:47PM UTC coverage: 74.862% (-0.2%) from 75.031%
18300593117

push

github

web-flow
Merge pull request #759 from wdhawkins/performance

Sweep performance optimizations

294 of 302 new or added lines in 15 files covered. (97.35%)

334 existing lines in 80 files now uncovered.

17788 of 23761 relevant lines covered (74.86%)

61852783.95 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

50.0
/framework/math/linear_solver/linear_solver_context.h
1
// SPDX-FileCopyrightText: 2024 The OpenSn Authors <https://open-sn.github.io/opensn/>
2
// SPDX-License-Identifier: MIT
3

4
#pragma once
5

6
#include <petscksp.h>
7

8
namespace opensn
9
{
10

11
enum class ResidualScaleType
12
{
13
  NONE = 0,
14
  RHS_NORM = 1,
15
  RHS_PRECONDITIONED_NORM = 2,
16
  CUSTOM_SCALE = 3
17
};
18

19
struct LinearSolverContext
20
{
UNCOV
21
  virtual int MatrixAction(Mat& matrix, Vec& vector, Vec& action) { return 0; }
×
22

23
  virtual ~LinearSolverContext() = default;
344✔
24
};
25

26
struct LinearSystemContext : public LinearSolverContext
27
{
28
  double rhs_norm = 0.0;
29
  double rhs_preconditioned_norm = 0.0;
30
  double custom_residual_scale = 1.0;
31
  ResidualScaleType residual_scale_type = ResidualScaleType::NONE;
32
};
33

34
struct LinearEigenContext : public LinearSolverContext
35
{
36
  double eigenvalue = 0.0;
37
};
38

39
} // namespace opensn
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc