-
Notifications
You must be signed in to change notification settings - Fork 248
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #3069 from KratosMultiphysics/core/add-sum-to-matrix
Adding sum to amatrix interface
- Loading branch information
Showing
2 changed files
with
51 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,37 @@ | ||
// | / | | ||
// ' / __| _` | __| _ \ __| | ||
// . \ | ( | | ( |\__ ` | ||
// _|\_\_| \__,_|\__|\___/ ____/ | ||
// Multi-Physics | ||
// | ||
// License: BSD License | ||
// Kratos default license: kratos/license.txt | ||
// | ||
// Main authors: Pooyan Dadvand | ||
// | ||
// | ||
|
||
// System includes | ||
|
||
|
||
// External includes | ||
|
||
#ifdef KRATOS_USE_AMATRIX // This macro definition is for the migration period and to be removed afterward please do not use it | ||
|
||
// Project includes | ||
#include "testing/testing.h" | ||
#include "includes/amatrix_interface.h" | ||
|
||
|
||
namespace Kratos { | ||
namespace Testing { | ||
|
||
KRATOS_TEST_CASE_IN_SUITE(AMatrixSum, KratosCoreFastSuite) | ||
{ | ||
DenseVector<double> a{ 1.0, 2.0, 3.1 }; | ||
KRATOS_CHECK_EQUAL(sum(a), 6.1); | ||
} | ||
|
||
} | ||
} // namespace Kratos. | ||
#endif // ifdef KRATOS_USE_AMATRIX |