Skip to content

Setup for 1.0.0 release#6

Draft
MitchellThompkins wants to merge 113 commits intomainfrom
develop
Draft

Setup for 1.0.0 release#6
MitchellThompkins wants to merge 113 commits intomainfrom
develop

Conversation

@MitchellThompkins
Copy link
Owner

No description provided.

Comment on lines +22 to +23
for (int i = 0; i < 3; ++i)
for (int j = 0; j < 3; ++j) EXPECT_NEAR(sum(i, j), eigSum(i, j), kThresh);
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Use braces. A linter should also catch this.

// Use a slightly looser tolerance for tests involving iterative methods (QR, Eigen)
// compared to the strict symmetry check tolerance.
#ifndef CONSTEIG_TEST_TOLERANCE
#define CONSTEIG_TEST_TOLERANCE 1e-9F
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is this actually looser?

option(CONSTEIG_RAISE_COMPILER_LIMITS "Raise constexpr limits for all targets" OFF)
if(CONSTEIG_RAISE_COMPILER_LIMITS)
if(CMAKE_COMPILER_IS_GNUCXX OR CMAKE_CXX_COMPILER_ID MATCHES "GNU")
add_compile_options(-fconstexpr-ops-limit=1000000000)
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is here but it's also set for all the actual tests. Check if that's appropriate.

if(CMAKE_CXX_COMPILER_ID MATCHES "Clang")
add_compile_options(-fconstexpr-steps=1000000000)
endif()
add_compile_options(-fconstexpr-depth=1024)
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Check this against the depth of the recursion limit in while loops in the constexpr functions.

Comment on lines +27 to +28
set(CMAKE_ARCHIVE_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
set(CMAKE_LIBRARY_OUTPUT_DIRECTORY ${CMAKE_BINARY_DIR}/lib)
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we even need these? We don't make libs.


#ifndef CONSTEIG_DEFAULT_SYMMETRIC_TOLERANCE
#define CONSTEIG_DEFAULT_SYMMETRIC_TOLERANCE 1e-6
#define CONSTEIG_DEFAULT_SYMMETRIC_TOLERANCE 1e-6
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This feels loosse? Check where it's used.

@MitchellThompkins MitchellThompkins changed the title Develop Setup for 1.0.0 release. Feb 19, 2026
@MitchellThompkins MitchellThompkins changed the title Setup for 1.0.0 release. Setup for 1.0.0 release Feb 19, 2026
std::complex<double> p1_c(poles_c(0, 0).real, poles_c(0, 0).imag);
std::complex<double> p2_c(poles_c(1, 0).real, poles_c(1, 0).imag);

std::complex<double> p1_d = std::exp(p1_c * T);
Copy link
Owner Author

@MitchellThompkins MitchellThompkins Feb 19, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should have a constexpr variant as well.


// 1. Find Continuous-time Eigenvalues (Poles) using Consteig
// This calculates the poles directly from the system matrix.
consteig::Matrix<consteig::Complex<double>, 2, 1> poles_c = consteig::eigvals(A_c);
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shouldn't template type deduction figure out the sizing here without me needing to specify it?

Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No but I think we can probably use auto with c++17 to figure it out.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Comments