sleipnirgroup-jormungandr 0.6.7.dev114__tar.gz → 0.6.7.dev115__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of sleipnirgroup-jormungandr might be problematic. Click here for more details.
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/PKG-INFO +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/variable_block.hpp +2 -3
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/variable_matrix.hpp +6 -11
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/problem.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/ipm.hpp +6 -8
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/ipm_matrix_callbacks.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/iteration_info.hpp +4 -4
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/newton.hpp +7 -7
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/newton_matrix_callbacks.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/sqp.hpp +6 -8
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/sqp_matrix_callbacks.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/append_as_triplets.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/constraint_violation.hpp +4 -4
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/dense_kkt_solver.hpp +2 -2
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/feasibility_restoration.hpp +12 -17
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/filter.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/fraction_to_the_boundary_rule.hpp +3 -3
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/inertia.hpp +2 -4
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/kkt_error.hpp +27 -31
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/kkt_solver.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/problem_scaling.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/sparse_inf_norms.hpp +2 -2
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/sparse_kkt_solver.hpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/print_diagnostics.hpp +5 -6
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/autodiff/bind_variable_block.cpp +2 -3
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/autodiff/bind_variable_matrix.cpp +4 -4
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/try_cast.hpp +1 -2
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/src/sleipnir/__init__.py +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/optimization/solver/ipm.cpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/optimization/solver/newton.cpp +1 -1
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/optimization/solver/sqp.cpp +1 -2
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/CMakeLists.txt +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/LICENSE.txt +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/README.md +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/SleipnirConfig.cmake.in +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/cmake/BuildTypes.cmake +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/cmake/CompilerFlags.cmake +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/cmake/Pybind11Mkdoc.cmake +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/cmake/Pybind11MkdocPostprocess.cmake +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/cmake/SubdirList.cmake +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/cmake/aarch64-linux-gnu.cmake +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/cmake/arm-none-eabi.cmake +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/expression.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/expression_functions.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/expression_graph.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/expression_type.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/gradient.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/hessian.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/jacobian.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/sleipnir_base.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/slice.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/autodiff/variable.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/multistart.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/ocp/dynamics_type.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/ocp/timestep_method.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/ocp/transcription_method.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/ocp.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/exit_status.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/options.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/all_finite.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/bounds.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/feasibility_restoration_cycle_detector.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/optimization/solver/util/time_trace.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/assert.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/concepts.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/empty.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/force_inline.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/function_ref.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/intrusive_shared_ptr.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/pool.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/print.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/scope_exit.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/spy.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/symbol_exports.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/include/sleipnir/util/time_tracer.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/pyproject.toml +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/arity.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/autodiff/bind_expression_type.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/autodiff/bind_gradient.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/autodiff/bind_hessian.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/autodiff/bind_jacobian.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/autodiff/bind_variable.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/binders.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/docstrings.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/for_each_type.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/main.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/bind_equality_constraints.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/bind_inequality_constraints.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/bind_ocp.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/bind_problem.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/ocp/bind_dynamics_type.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/ocp/bind_timestep_method.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/ocp/bind_transcription_method.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/solver/bind_exit_status.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/optimization/solver/bind_iteration_info.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/slice_tuple.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/cpp/text_wrap.hpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/postprocess_stubs.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/src/sleipnir/autodiff/__init__.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/src/sleipnir/optimization/__init__.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/autodiff/gradient_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/autodiff/hessian_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/autodiff/jacobian_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/autodiff/variable_matrix_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/autodiff/variable_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/arm_on_elevator_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/cart_pole_ocp_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/cart_pole_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/cart_pole_util.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/constraints_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/decision_variable_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/differential_drive_ocp_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/differential_drive_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/differential_drive_util.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/double_integrator_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/flywheel_ocp_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/flywheel_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/flywheel_util.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/linear_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/multistart_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/nonlinear_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/problem_spy_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/quadratic_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/rk4.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/solver/exit_status_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/python/test/optimization/trivial_problem_test.py +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/autodiff/gradient.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/autodiff/hessian.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/autodiff/jacobian.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/autodiff/variable_matrix.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/optimization/ocp.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/optimization/problem.cpp +0 -0
- {sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/util/pool.cpp +0 -0
|
@@ -593,9 +593,8 @@ class VariableBlock : public SleipnirBase {
|
|
|
593
593
|
/// Returns the contents of the variable matrix.
|
|
594
594
|
///
|
|
595
595
|
/// @return The contents of the variable matrix.
|
|
596
|
-
Eigen::
|
|
597
|
-
Eigen::
|
|
598
|
-
cols()};
|
|
596
|
+
Eigen::MatrixX<Scalar> value() {
|
|
597
|
+
Eigen::MatrixX<Scalar> result{rows(), cols()};
|
|
599
598
|
|
|
600
599
|
for (int row = 0; row < rows(); ++row) {
|
|
601
600
|
for (int col = 0; col < cols(); ++col) {
|
|
@@ -990,9 +990,8 @@ class VariableMatrix : public SleipnirBase {
|
|
|
990
990
|
/// Returns the contents of the variable matrix.
|
|
991
991
|
///
|
|
992
992
|
/// @return The contents of the variable matrix.
|
|
993
|
-
Eigen::
|
|
994
|
-
Eigen::
|
|
995
|
-
cols()};
|
|
993
|
+
Eigen::MatrixX<Scalar> value() {
|
|
994
|
+
Eigen::MatrixX<Scalar> result{rows(), cols()};
|
|
996
995
|
|
|
997
996
|
for (int row = 0; row < rows(); ++row) {
|
|
998
997
|
for (int col = 0; col < cols(); ++col) {
|
|
@@ -1006,10 +1005,8 @@ class VariableMatrix : public SleipnirBase {
|
|
|
1006
1005
|
/// Converts the VariableMatrix to an Eigen matrix.
|
|
1007
1006
|
///
|
|
1008
1007
|
/// @return Eigen matrix.
|
|
1009
|
-
Eigen::
|
|
1010
|
-
|
|
1011
|
-
Eigen::Matrix<Variable<Scalar>, Eigen::Dynamic, Eigen::Dynamic> result{
|
|
1012
|
-
rows(), cols()};
|
|
1008
|
+
Eigen::MatrixX<Variable<Scalar>> to_eigen() const {
|
|
1009
|
+
Eigen::MatrixX<Variable<Scalar>> result{rows(), cols()};
|
|
1013
1010
|
|
|
1014
1011
|
for (int row = 0; row < rows(); ++row) {
|
|
1015
1012
|
for (int col = 0; col < cols(); ++col) {
|
|
@@ -1104,11 +1101,9 @@ class VariableMatrix : public SleipnirBase {
|
|
|
1104
1101
|
// Q = Σ qₖAᵏ
|
|
1105
1102
|
// k=0
|
|
1106
1103
|
VariableMatrix<Scalar> P{
|
|
1107
|
-
Eigen::
|
|
1108
|
-
.asDiagonal()};
|
|
1104
|
+
Eigen::VectorX<Scalar>::Constant(rows(), p[0]).asDiagonal()};
|
|
1109
1105
|
VariableMatrix<Scalar> Q{
|
|
1110
|
-
Eigen::
|
|
1111
|
-
.asDiagonal()};
|
|
1106
|
+
Eigen::VectorX<Scalar>::Constant(rows(), q[0]).asDiagonal()};
|
|
1112
1107
|
auto A_pow = *this;
|
|
1113
1108
|
size_t k = 1;
|
|
1114
1109
|
while (true) {
|
|
@@ -71,8 +71,8 @@ ExitStatus ipm(const IPMMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
|
71
71
|
#ifdef SLEIPNIR_ENABLE_BOUND_PROJECTION
|
|
72
72
|
const Eigen::ArrayX<bool>& bound_constraint_mask,
|
|
73
73
|
#endif
|
|
74
|
-
Eigen::
|
|
75
|
-
using DenseVector = Eigen::
|
|
74
|
+
Eigen::VectorX<Scalar>& x) {
|
|
75
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
76
76
|
|
|
77
77
|
// If cᵢ(x) is sufficiently feasible, start the constraint with zero
|
|
78
78
|
// violation. Otherwise, make Σ = S⁻¹Z ≈ I.
|
|
@@ -133,12 +133,10 @@ ExitStatus ipm(const IPMMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
|
133
133
|
#ifdef SLEIPNIR_ENABLE_BOUND_PROJECTION
|
|
134
134
|
const Eigen::ArrayX<bool>& bound_constraint_mask,
|
|
135
135
|
#endif
|
|
136
|
-
Eigen::
|
|
137
|
-
Eigen::
|
|
138
|
-
Eigen::Vector<Scalar, Eigen::Dynamic>& y,
|
|
139
|
-
Eigen::Vector<Scalar, Eigen::Dynamic>& z, Scalar& μ,
|
|
136
|
+
Eigen::VectorX<Scalar>& x, Eigen::VectorX<Scalar>& s,
|
|
137
|
+
Eigen::VectorX<Scalar>& y, Eigen::VectorX<Scalar>& z, Scalar& μ,
|
|
140
138
|
int& iterations) {
|
|
141
|
-
using DenseVector = Eigen::
|
|
139
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
142
140
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
143
141
|
using SparseVector = Eigen::SparseVector<Scalar>;
|
|
144
142
|
|
|
@@ -888,6 +886,6 @@ ipm(const IPMMatrixCallbacks<double>& matrix_callbacks,
|
|
|
888
886
|
#ifdef SLEIPNIR_ENABLE_BOUND_PROJECTION
|
|
889
887
|
const Eigen::ArrayX<bool>& bound_constraint_mask,
|
|
890
888
|
#endif
|
|
891
|
-
Eigen::
|
|
889
|
+
Eigen::VectorX<double>& x);
|
|
892
890
|
|
|
893
891
|
} // namespace slp
|
|
@@ -17,7 +17,7 @@ namespace slp {
|
|
|
17
17
|
template <typename Scalar>
|
|
18
18
|
struct IPMMatrixCallbacks {
|
|
19
19
|
/// Type alias for dense vector.
|
|
20
|
-
using DenseVector = Eigen::
|
|
20
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
21
21
|
/// Type alias for sparse matrix.
|
|
22
22
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
23
23
|
/// Type alias for sparse vector.
|
|
@@ -16,16 +16,16 @@ struct IterationInfo {
|
|
|
16
16
|
int iteration;
|
|
17
17
|
|
|
18
18
|
/// The decision variables.
|
|
19
|
-
const Eigen::
|
|
19
|
+
const Eigen::VectorX<Scalar>& x;
|
|
20
20
|
|
|
21
21
|
/// The inequality constraint slack variables.
|
|
22
|
-
const Eigen::
|
|
22
|
+
const Eigen::VectorX<Scalar>& s;
|
|
23
23
|
|
|
24
24
|
/// The equality constraint dual variables.
|
|
25
|
-
const Eigen::
|
|
25
|
+
const Eigen::VectorX<Scalar>& y;
|
|
26
26
|
|
|
27
27
|
/// The inequality constraint dual variables.
|
|
28
|
-
const Eigen::
|
|
28
|
+
const Eigen::VectorX<Scalar>& z;
|
|
29
29
|
|
|
30
30
|
/// The gradient of the cost function.
|
|
31
31
|
const Eigen::SparseVector<Scalar>& g;
|
|
@@ -54,8 +54,8 @@ ExitStatus newton(
|
|
|
54
54
|
const NewtonMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
55
55
|
std::span<std::function<bool(const IterationInfo<Scalar>& info)>>
|
|
56
56
|
iteration_callbacks,
|
|
57
|
-
const Options<Scalar>& options, Eigen::
|
|
58
|
-
using DenseVector = Eigen::
|
|
57
|
+
const Options<Scalar>& options, Eigen::VectorX<Scalar>& x) {
|
|
58
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
59
59
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
60
60
|
using SparseVector = Eigen::SparseVector<Scalar>;
|
|
61
61
|
|
|
@@ -288,10 +288,10 @@ ExitStatus newton(
|
|
|
288
288
|
}
|
|
289
289
|
}
|
|
290
290
|
|
|
291
|
-
extern template SLEIPNIR_DLLEXPORT ExitStatus
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
291
|
+
extern template SLEIPNIR_DLLEXPORT ExitStatus
|
|
292
|
+
newton(const NewtonMatrixCallbacks<double>& matrix_callbacks,
|
|
293
|
+
std::span<std::function<bool(const IterationInfo<double>& info)>>
|
|
294
|
+
iteration_callbacks,
|
|
295
|
+
const Options<double>& options, Eigen::VectorX<double>& x);
|
|
296
296
|
|
|
297
297
|
} // namespace slp
|
|
@@ -17,7 +17,7 @@ namespace slp {
|
|
|
17
17
|
template <typename Scalar>
|
|
18
18
|
struct NewtonMatrixCallbacks {
|
|
19
19
|
/// Type alias for dense vector.
|
|
20
|
-
using DenseVector = Eigen::
|
|
20
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
21
21
|
/// Type alias for sparse matrix.
|
|
22
22
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
23
23
|
/// Type alias for sparse vector.
|
|
@@ -61,9 +61,8 @@ template <typename Scalar>
|
|
|
61
61
|
ExitStatus sqp(const SQPMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
62
62
|
std::span<std::function<bool(const IterationInfo<Scalar>& info)>>
|
|
63
63
|
iteration_callbacks,
|
|
64
|
-
const Options<Scalar>& options,
|
|
65
|
-
|
|
66
|
-
using DenseVector = Eigen::Vector<Scalar, Eigen::Dynamic>;
|
|
64
|
+
const Options<Scalar>& options, Eigen::VectorX<Scalar>& x) {
|
|
65
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
67
66
|
|
|
68
67
|
DenseVector y = DenseVector::Zero(matrix_callbacks.num_equality_constraints);
|
|
69
68
|
|
|
@@ -96,10 +95,9 @@ template <typename Scalar>
|
|
|
96
95
|
ExitStatus sqp(const SQPMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
97
96
|
std::span<std::function<bool(const IterationInfo<Scalar>& info)>>
|
|
98
97
|
iteration_callbacks,
|
|
99
|
-
const Options<Scalar>& options,
|
|
100
|
-
Eigen::
|
|
101
|
-
|
|
102
|
-
using DenseVector = Eigen::Vector<Scalar, Eigen::Dynamic>;
|
|
98
|
+
const Options<Scalar>& options, Eigen::VectorX<Scalar>& x,
|
|
99
|
+
Eigen::VectorX<Scalar>& y) {
|
|
100
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
103
101
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
104
102
|
using SparseVector = Eigen::SparseVector<Scalar>;
|
|
105
103
|
|
|
@@ -627,6 +625,6 @@ extern template SLEIPNIR_DLLEXPORT ExitStatus
|
|
|
627
625
|
sqp(const SQPMatrixCallbacks<double>& matrix_callbacks,
|
|
628
626
|
std::span<std::function<bool(const IterationInfo<double>& info)>>
|
|
629
627
|
iteration_callbacks,
|
|
630
|
-
const Options<double>& options, Eigen::
|
|
628
|
+
const Options<double>& options, Eigen::VectorX<double>& x);
|
|
631
629
|
|
|
632
630
|
} // namespace slp
|
|
@@ -17,7 +17,7 @@ namespace slp {
|
|
|
17
17
|
template <typename Scalar>
|
|
18
18
|
struct SQPMatrixCallbacks {
|
|
19
19
|
/// Type alias for dense vector.
|
|
20
|
-
using DenseVector = Eigen::
|
|
20
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
21
21
|
/// Type alias for sparse matrix.
|
|
22
22
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
23
23
|
/// Type alias for sparse vector.
|
|
@@ -57,7 +57,7 @@ void append_as_triplets(
|
|
|
57
57
|
template <typename Scalar>
|
|
58
58
|
void append_diagonal_as_triplets(
|
|
59
59
|
gch::small_vector<Eigen::Triplet<Scalar>>& triplets, int row_offset,
|
|
60
|
-
int col_offset, const Eigen::
|
|
60
|
+
int col_offset, const Eigen::VectorX<Scalar>& diag) {
|
|
61
61
|
for (int row = 0; row < diag.rows(); ++row) {
|
|
62
62
|
triplets.emplace_back(row_offset + row, col_offset + row, diag[row]);
|
|
63
63
|
}
|
|
@@ -13,7 +13,7 @@ namespace slp {
|
|
|
13
13
|
/// @param c_e The equality constraint values (nonzero means violation).
|
|
14
14
|
/// @return The constraint violation.
|
|
15
15
|
template <typename Scalar>
|
|
16
|
-
Scalar constraint_violation(const Eigen::
|
|
16
|
+
Scalar constraint_violation(const Eigen::VectorX<Scalar>& c_e) {
|
|
17
17
|
return c_e.template lpNorm<1>();
|
|
18
18
|
}
|
|
19
19
|
|
|
@@ -25,9 +25,9 @@ Scalar constraint_violation(const Eigen::Vector<Scalar, Eigen::Dynamic>& c_e) {
|
|
|
25
25
|
/// @param s The inequality constraint slack variables.
|
|
26
26
|
/// @return The constraint violation.
|
|
27
27
|
template <typename Scalar>
|
|
28
|
-
Scalar constraint_violation(const Eigen::
|
|
29
|
-
const Eigen::
|
|
30
|
-
const Eigen::
|
|
28
|
+
Scalar constraint_violation(const Eigen::VectorX<Scalar>& c_e,
|
|
29
|
+
const Eigen::VectorX<Scalar>& c_i,
|
|
30
|
+
const Eigen::VectorX<Scalar>& s) {
|
|
31
31
|
return c_e.template lpNorm<1>() + (c_i - s).template lpNorm<1>();
|
|
32
32
|
}
|
|
33
33
|
|
|
@@ -20,9 +20,9 @@ template <typename Scalar>
|
|
|
20
20
|
class DenseKKTSolver {
|
|
21
21
|
public:
|
|
22
22
|
/// Type alias for dense matrix.
|
|
23
|
-
using DenseMatrix = Eigen::
|
|
23
|
+
using DenseMatrix = Eigen::MatrixX<Scalar>;
|
|
24
24
|
/// Type alias for dense vector.
|
|
25
|
-
using DenseVector = Eigen::
|
|
25
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
26
26
|
|
|
27
27
|
/// Constructs a DenseKKTSolver instance.
|
|
28
28
|
///
|
|
@@ -32,10 +32,8 @@ ExitStatus ipm(const IPMMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
|
32
32
|
#ifdef SLEIPNIR_ENABLE_BOUND_PROJECTION
|
|
33
33
|
const Eigen::ArrayX<bool>& bound_constraint_mask,
|
|
34
34
|
#endif
|
|
35
|
-
Eigen::
|
|
36
|
-
Eigen::
|
|
37
|
-
Eigen::Vector<Scalar, Eigen::Dynamic>& y,
|
|
38
|
-
Eigen::Vector<Scalar, Eigen::Dynamic>& z, Scalar& μ,
|
|
35
|
+
Eigen::VectorX<Scalar>& x, Eigen::VectorX<Scalar>& s,
|
|
36
|
+
Eigen::VectorX<Scalar>& y, Eigen::VectorX<Scalar>& z, Scalar& μ,
|
|
39
37
|
int& iterations);
|
|
40
38
|
|
|
41
39
|
/// Computes initial values for p and n in feasibility restoration.
|
|
@@ -47,10 +45,8 @@ ExitStatus ipm(const IPMMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
|
47
45
|
/// @return Tuple of positive and negative constraint relaxation slack variables
|
|
48
46
|
/// respectively.
|
|
49
47
|
template <typename Scalar>
|
|
50
|
-
std::tuple<Eigen::
|
|
51
|
-
|
|
52
|
-
compute_p_n(const Eigen::Vector<Scalar, Eigen::Dynamic>& c, Scalar ρ,
|
|
53
|
-
Scalar μ) {
|
|
48
|
+
std::tuple<Eigen::VectorX<Scalar>, Eigen::VectorX<Scalar>> compute_p_n(
|
|
49
|
+
const Eigen::VectorX<Scalar>& c, Scalar ρ, Scalar μ) {
|
|
54
50
|
// From equation (33) of [2]:
|
|
55
51
|
// ______________________
|
|
56
52
|
// μ − ρ c(x) /(μ − ρ c(x))² μ c(x)
|
|
@@ -81,7 +77,7 @@ compute_p_n(const Eigen::Vector<Scalar, Eigen::Dynamic>& c, Scalar ρ,
|
|
|
81
77
|
//
|
|
82
78
|
// p = c(x) + n (6)
|
|
83
79
|
|
|
84
|
-
using DenseVector = Eigen::
|
|
80
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
85
81
|
|
|
86
82
|
using std::sqrt;
|
|
87
83
|
|
|
@@ -119,8 +115,8 @@ ExitStatus feasibility_restoration(
|
|
|
119
115
|
const SQPMatrixCallbacks<Scalar>& matrix_callbacks,
|
|
120
116
|
std::span<std::function<bool(const IterationInfo<Scalar>& info)>>
|
|
121
117
|
iteration_callbacks,
|
|
122
|
-
const Options<Scalar>& options, Eigen::
|
|
123
|
-
Eigen::
|
|
118
|
+
const Options<Scalar>& options, Eigen::VectorX<Scalar>& x,
|
|
119
|
+
Eigen::VectorX<Scalar>& y, int& iterations) {
|
|
124
120
|
// Feasibility restoration
|
|
125
121
|
//
|
|
126
122
|
// min ρ Σ (pₑ + nₑ) + ζ/2 (x - xᵣ)ᵀDᵣ(x - xᵣ)
|
|
@@ -137,7 +133,7 @@ ExitStatus feasibility_restoration(
|
|
|
137
133
|
//
|
|
138
134
|
// Dᵣ = diag(min(1, 1/xᵣ[i]²) for i in x.rows())
|
|
139
135
|
|
|
140
|
-
using DenseVector = Eigen::
|
|
136
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
141
137
|
using DiagonalMatrix = Eigen::DiagonalMatrix<Scalar, Eigen::Dynamic>;
|
|
142
138
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
143
139
|
using SparseVector = Eigen::SparseVector<Scalar>;
|
|
@@ -381,10 +377,9 @@ ExitStatus feasibility_restoration(
|
|
|
381
377
|
#ifdef SLEIPNIR_ENABLE_BOUND_PROJECTION
|
|
382
378
|
const Eigen::ArrayX<bool>& bound_constraint_mask,
|
|
383
379
|
#endif
|
|
384
|
-
Eigen::
|
|
385
|
-
Eigen::
|
|
386
|
-
|
|
387
|
-
Eigen::Vector<Scalar, Eigen::Dynamic>& z, Scalar μ, int& iterations) {
|
|
380
|
+
Eigen::VectorX<Scalar>& x, Eigen::VectorX<Scalar>& s,
|
|
381
|
+
Eigen::VectorX<Scalar>& y, Eigen::VectorX<Scalar>& z, Scalar μ,
|
|
382
|
+
int& iterations) {
|
|
388
383
|
// Feasibility restoration
|
|
389
384
|
//
|
|
390
385
|
// min ρ Σ (pₑ + nₑ + pᵢ + nᵢ) + ζ/2 (x - xᵣ)ᵀDᵣ(x - xᵣ)
|
|
@@ -405,7 +400,7 @@ ExitStatus feasibility_restoration(
|
|
|
405
400
|
//
|
|
406
401
|
// Dᵣ = diag(min(1, 1/xᵣ[i]²) for i in x.rows())
|
|
407
402
|
|
|
408
|
-
using DenseVector = Eigen::
|
|
403
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
409
404
|
using DiagonalMatrix = Eigen::DiagonalMatrix<Scalar, Eigen::Dynamic>;
|
|
410
405
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
411
406
|
using SparseVector = Eigen::SparseVector<Scalar>;
|
|
@@ -20,7 +20,7 @@ namespace slp {
|
|
|
20
20
|
template <typename Scalar>
|
|
21
21
|
struct FilterEntry {
|
|
22
22
|
/// Type alias for dense vector.
|
|
23
|
-
using DenseVector = Eigen::
|
|
23
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
24
24
|
|
|
25
25
|
/// The cost function's value
|
|
26
26
|
Scalar cost{0};
|
|
@@ -17,9 +17,9 @@ namespace slp {
|
|
|
17
17
|
/// @param τ Fraction-to-the-boundary rule scaling factor within (0, 1].
|
|
18
18
|
/// @return Fraction of the iterate step size within (0, 1].
|
|
19
19
|
template <typename Scalar>
|
|
20
|
-
Scalar fraction_to_the_boundary_rule(
|
|
21
|
-
|
|
22
|
-
|
|
20
|
+
Scalar fraction_to_the_boundary_rule(const Eigen::VectorX<Scalar>& x,
|
|
21
|
+
const Eigen::VectorX<Scalar>& p,
|
|
22
|
+
Scalar τ) {
|
|
23
23
|
// The fraction-to-the-boundary rule is defined as:
|
|
24
24
|
//
|
|
25
25
|
// α = max(α ∈ (0, 1] : x + αp ≥ (1 − τ)x) (1)
|
|
@@ -37,7 +37,7 @@ class Inertia {
|
|
|
37
37
|
/// @tparam Scalar Scalar type.
|
|
38
38
|
/// @param D The D matrix of an LDLT decomposition in vector form.
|
|
39
39
|
template <typename Scalar>
|
|
40
|
-
explicit Inertia(const Eigen::
|
|
40
|
+
explicit Inertia(const Eigen::VectorX<Scalar>& D) {
|
|
41
41
|
for (const auto& elem : D) {
|
|
42
42
|
if (elem > std::numeric_limits<Scalar>::epsilon()) {
|
|
43
43
|
++positive;
|
|
@@ -55,9 +55,7 @@ class Inertia {
|
|
|
55
55
|
/// @tparam Scalar Scalar type.
|
|
56
56
|
/// @param D The D matrix of an LDLT decomposition in vector form.
|
|
57
57
|
template <typename Scalar>
|
|
58
|
-
explicit Inertia(
|
|
59
|
-
const Eigen::Diagonal<
|
|
60
|
-
const Eigen::Matrix<Scalar, Eigen::Dynamic, Eigen::Dynamic>>& D) {
|
|
58
|
+
explicit Inertia(const Eigen::Diagonal<const Eigen::MatrixX<Scalar>>& D) {
|
|
61
59
|
for (const auto& elem : D) {
|
|
62
60
|
if (elem > std::numeric_limits<Scalar>::epsilon()) {
|
|
63
61
|
++positive;
|
|
@@ -27,7 +27,7 @@ enum class KKTErrorType {
|
|
|
27
27
|
/// @tparam T Type of KKT error to compute.
|
|
28
28
|
/// @param g Cost function gradient ∇f.
|
|
29
29
|
template <typename Scalar, KKTErrorType T>
|
|
30
|
-
Scalar kkt_error(const Eigen::
|
|
30
|
+
Scalar kkt_error(const Eigen::VectorX<Scalar>& g) {
|
|
31
31
|
// The KKT conditions from docs/algorithms.md:
|
|
32
32
|
//
|
|
33
33
|
// ∇f = 0
|
|
@@ -48,10 +48,10 @@ Scalar kkt_error(const Eigen::Vector<Scalar, Eigen::Dynamic>& g) {
|
|
|
48
48
|
/// @param c_e Equality constraints cₑ(x).
|
|
49
49
|
/// @param y Equality constraint dual variables.
|
|
50
50
|
template <typename Scalar, KKTErrorType T>
|
|
51
|
-
Scalar kkt_error(const Eigen::
|
|
51
|
+
Scalar kkt_error(const Eigen::VectorX<Scalar>& g,
|
|
52
52
|
const Eigen::SparseMatrix<Scalar>& A_e,
|
|
53
|
-
const Eigen::
|
|
54
|
-
const Eigen::
|
|
53
|
+
const Eigen::VectorX<Scalar>& c_e,
|
|
54
|
+
const Eigen::VectorX<Scalar>& y) {
|
|
55
55
|
// The KKT conditions from docs/algorithms.md:
|
|
56
56
|
//
|
|
57
57
|
// ∇f − Aₑᵀy = 0
|
|
@@ -90,14 +90,14 @@ Scalar kkt_error(const Eigen::Vector<Scalar, Eigen::Dynamic>& g,
|
|
|
90
90
|
/// @param z Inequality constraint dual variables.
|
|
91
91
|
/// @param μ Barrier parameter.
|
|
92
92
|
template <typename Scalar, KKTErrorType T>
|
|
93
|
-
Scalar kkt_error(const Eigen::
|
|
93
|
+
Scalar kkt_error(const Eigen::VectorX<Scalar>& g,
|
|
94
94
|
const Eigen::SparseMatrix<Scalar>& A_e,
|
|
95
|
-
const Eigen::
|
|
95
|
+
const Eigen::VectorX<Scalar>& c_e,
|
|
96
96
|
const Eigen::SparseMatrix<Scalar>& A_i,
|
|
97
|
-
const Eigen::
|
|
98
|
-
const Eigen::
|
|
99
|
-
const Eigen::
|
|
100
|
-
const Eigen::
|
|
97
|
+
const Eigen::VectorX<Scalar>& c_i,
|
|
98
|
+
const Eigen::VectorX<Scalar>& s,
|
|
99
|
+
const Eigen::VectorX<Scalar>& y,
|
|
100
|
+
const Eigen::VectorX<Scalar>& z, Scalar μ) {
|
|
101
101
|
// The KKT conditions from docs/algorithms.md:
|
|
102
102
|
//
|
|
103
103
|
// ∇f − Aₑᵀy − Aᵢᵀz = 0
|
|
@@ -120,8 +120,8 @@ Scalar kkt_error(const Eigen::Vector<Scalar, Eigen::Dynamic>& g,
|
|
|
120
120
|
std::max(s_max, z.template lpNorm<1>() / Scalar(z.rows())) / s_max;
|
|
121
121
|
|
|
122
122
|
const auto S = s.asDiagonal();
|
|
123
|
-
const Eigen::
|
|
124
|
-
Eigen::
|
|
123
|
+
const Eigen::VectorX<Scalar> μe =
|
|
124
|
+
Eigen::VectorX<Scalar>::Constant(s.rows(), μ);
|
|
125
125
|
|
|
126
126
|
// ‖∇f − Aₑᵀy − Aᵢᵀz‖_∞ / s_d
|
|
127
127
|
// ‖Sz − μe‖_∞ / s_c
|
|
@@ -135,8 +135,8 @@ Scalar kkt_error(const Eigen::Vector<Scalar, Eigen::Dynamic>& g,
|
|
|
135
135
|
(c_i - s).template lpNorm<Eigen::Infinity>()});
|
|
136
136
|
} else if constexpr (T == KKTErrorType::ONE_NORM) {
|
|
137
137
|
const auto S = s.asDiagonal();
|
|
138
|
-
const Eigen::
|
|
139
|
-
Eigen::
|
|
138
|
+
const Eigen::VectorX<Scalar> μe =
|
|
139
|
+
Eigen::VectorX<Scalar>::Constant(s.rows(), μ);
|
|
140
140
|
|
|
141
141
|
return (g - A_e.transpose() * y - A_i.transpose() * z)
|
|
142
142
|
.template lpNorm<1>() +
|
|
@@ -153,8 +153,8 @@ Scalar kkt_error(const Eigen::Vector<Scalar, Eigen::Dynamic>& g,
|
|
|
153
153
|
/// @param g Scaled cost function gradient d_f·∇f.
|
|
154
154
|
template <typename Scalar, KKTErrorType T>
|
|
155
155
|
Scalar unscaled_kkt_error(const ProblemScaling<Scalar>& scaling,
|
|
156
|
-
const Eigen::
|
|
157
|
-
using DenseVector = Eigen::
|
|
156
|
+
const Eigen::VectorX<Scalar>& g) {
|
|
157
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
158
158
|
|
|
159
159
|
if (scaling.is_identity()) {
|
|
160
160
|
return kkt_error<Scalar, T>(g);
|
|
@@ -176,11 +176,11 @@ Scalar unscaled_kkt_error(const ProblemScaling<Scalar>& scaling,
|
|
|
176
176
|
/// @param y Scaled equality constraint dual variables.
|
|
177
177
|
template <typename Scalar, KKTErrorType T>
|
|
178
178
|
Scalar unscaled_kkt_error(const ProblemScaling<Scalar>& scaling,
|
|
179
|
-
const Eigen::
|
|
179
|
+
const Eigen::VectorX<Scalar>& g,
|
|
180
180
|
const Eigen::SparseMatrix<Scalar>& A_e,
|
|
181
|
-
const Eigen::
|
|
182
|
-
const Eigen::
|
|
183
|
-
using DenseVector = Eigen::
|
|
181
|
+
const Eigen::VectorX<Scalar>& c_e,
|
|
182
|
+
const Eigen::VectorX<Scalar>& y) {
|
|
183
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
184
184
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
185
185
|
|
|
186
186
|
if (scaling.is_identity()) {
|
|
@@ -214,17 +214,13 @@ Scalar unscaled_kkt_error(const ProblemScaling<Scalar>& scaling,
|
|
|
214
214
|
/// @param z Scaled inequality constraint dual variables.
|
|
215
215
|
/// @param μ Scaled barrier parameter.
|
|
216
216
|
template <typename Scalar, KKTErrorType T>
|
|
217
|
-
Scalar unscaled_kkt_error(
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
const Eigen::Vector<Scalar, Eigen::Dynamic>& y,
|
|
225
|
-
const Eigen::Vector<Scalar, Eigen::Dynamic>& z,
|
|
226
|
-
Scalar μ) {
|
|
227
|
-
using DenseVector = Eigen::Vector<Scalar, Eigen::Dynamic>;
|
|
217
|
+
Scalar unscaled_kkt_error(
|
|
218
|
+
const ProblemScaling<Scalar>& scaling, const Eigen::VectorX<Scalar>& g,
|
|
219
|
+
const Eigen::SparseMatrix<Scalar>& A_e, const Eigen::VectorX<Scalar>& c_e,
|
|
220
|
+
const Eigen::SparseMatrix<Scalar>& A_i, const Eigen::VectorX<Scalar>& c_i,
|
|
221
|
+
const Eigen::VectorX<Scalar>& s, const Eigen::VectorX<Scalar>& y,
|
|
222
|
+
const Eigen::VectorX<Scalar>& z, Scalar μ) {
|
|
223
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
228
224
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
229
225
|
|
|
230
226
|
if (scaling.is_identity()) {
|
|
@@ -19,7 +19,7 @@ template <typename Scalar>
|
|
|
19
19
|
class KKTSolver {
|
|
20
20
|
public:
|
|
21
21
|
/// Type alias for dense vector.
|
|
22
|
-
using DenseVector = Eigen::
|
|
22
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
23
23
|
/// Type alias for sparse matrix.
|
|
24
24
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
25
25
|
|
|
@@ -20,7 +20,7 @@ namespace slp {
|
|
|
20
20
|
template <typename Scalar>
|
|
21
21
|
struct ProblemScaling {
|
|
22
22
|
/// Type alias for dense vector.
|
|
23
|
-
using DenseVector = Eigen::
|
|
23
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
24
24
|
/// Type alias for sparse matrix.
|
|
25
25
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
26
26
|
/// Type alias for sparse vector.
|
|
@@ -16,9 +16,9 @@ namespace slp {
|
|
|
16
16
|
/// corresponding row of the sparse matrix.
|
|
17
17
|
template <typename Derived>
|
|
18
18
|
auto sparse_inf_norms(const Eigen::SparseCompressedBase<Derived>& mat)
|
|
19
|
-
-> Eigen::
|
|
19
|
+
-> Eigen::VectorX<typename Derived::Scalar> {
|
|
20
20
|
using Scalar = typename Derived::Scalar;
|
|
21
|
-
using DenseVector = Eigen::
|
|
21
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
22
22
|
|
|
23
23
|
DenseVector norms = DenseVector::Zero(mat.rows());
|
|
24
24
|
for (int k = 0; k < mat.outerSize(); ++k) {
|
|
@@ -21,7 +21,7 @@ template <typename Scalar>
|
|
|
21
21
|
class SparseKKTSolver {
|
|
22
22
|
public:
|
|
23
23
|
/// Type alias for dense vector.
|
|
24
|
-
using DenseVector = Eigen::
|
|
24
|
+
using DenseVector = Eigen::VectorX<Scalar>;
|
|
25
25
|
/// Type alias for sparse matrix.
|
|
26
26
|
using SparseMatrix = Eigen::SparseMatrix<Scalar>;
|
|
27
27
|
|
|
@@ -93,8 +93,7 @@ std::string power_of_10(Scalar value) {
|
|
|
93
93
|
/// @param c_e The problem's equality constraints cₑ(x) evaluated at the current
|
|
94
94
|
/// iterate.
|
|
95
95
|
template <typename Scalar>
|
|
96
|
-
void print_too_few_dofs_error(
|
|
97
|
-
const Eigen::Vector<Scalar, Eigen::Dynamic>& c_e) {
|
|
96
|
+
void print_too_few_dofs_error(const Eigen::VectorX<Scalar>& c_e) {
|
|
98
97
|
slp::println("The problem has too few degrees of freedom.");
|
|
99
98
|
slp::println("Violated constraints (cₑ(x) = 0) in order of declaration:");
|
|
100
99
|
for (int row = 0; row < c_e.rows(); ++row) {
|
|
@@ -116,8 +115,8 @@ void print_too_few_dofs_error(
|
|
|
116
115
|
/// @param tolerance Constraint violations at or below this tolerance aren't
|
|
117
116
|
/// printed.
|
|
118
117
|
template <typename Scalar>
|
|
119
|
-
void print_c_e_local_infeasibility_error(
|
|
120
|
-
|
|
118
|
+
void print_c_e_local_infeasibility_error(const Eigen::VectorX<Scalar>& c_e,
|
|
119
|
+
Scalar tolerance) {
|
|
121
120
|
using std::abs;
|
|
122
121
|
|
|
123
122
|
slp::println(
|
|
@@ -143,8 +142,8 @@ void print_c_e_local_infeasibility_error(
|
|
|
143
142
|
/// @param tolerance Constraint violations at or below this tolerance aren't
|
|
144
143
|
/// printed.
|
|
145
144
|
template <typename Scalar>
|
|
146
|
-
void print_c_i_local_infeasibility_error(
|
|
147
|
-
|
|
145
|
+
void print_c_i_local_infeasibility_error(const Eigen::VectorX<Scalar>& c_i,
|
|
146
|
+
Scalar tolerance) {
|
|
148
147
|
slp::println(
|
|
149
148
|
"The problem is locally infeasible due to violated inequality "
|
|
150
149
|
"constraints.");
|
|
@@ -37,8 +37,6 @@ namespace slp {
|
|
|
37
37
|
void bind_variable_block(
|
|
38
38
|
nb::class_<VariableBlock<VariableMatrix<double>>>& cls) {
|
|
39
39
|
using namespace nb::literals;
|
|
40
|
-
using MatrixXi64 = Eigen::Matrix<int64_t, Eigen::Dynamic, Eigen::Dynamic>;
|
|
41
|
-
using MatrixXi32 = Eigen::Matrix<int32_t, Eigen::Dynamic, Eigen::Dynamic>;
|
|
42
40
|
|
|
43
41
|
cls.def(
|
|
44
42
|
"set_value",
|
|
@@ -51,7 +49,8 @@ void bind_variable_block(
|
|
|
51
49
|
[](VariableBlock<VariableMatrix<double>>& self,
|
|
52
50
|
nb::DRef<Eigen::MatrixXd> values) { self.set_value(values); },
|
|
53
51
|
"values"_a, DOC(slp, VariableBlock, set_value, 2));
|
|
54
|
-
for_each_type<Eigen::MatrixXf,
|
|
52
|
+
for_each_type<Eigen::MatrixXf, Eigen::MatrixX<int64_t>,
|
|
53
|
+
Eigen::MatrixX<int32_t>>([&]<typename T> {
|
|
55
54
|
cls.def(
|
|
56
55
|
"set_value",
|
|
57
56
|
[](VariableBlock<VariableMatrix<double>>& self, nb::DRef<T> values) {
|
|
@@ -38,8 +38,6 @@ namespace slp {
|
|
|
38
38
|
void bind_variable_matrix(nb::module_& autodiff,
|
|
39
39
|
nb::class_<VariableMatrix<double>>& cls) {
|
|
40
40
|
using namespace nb::literals;
|
|
41
|
-
using MatrixXi64 = Eigen::Matrix<int64_t, Eigen::Dynamic, Eigen::Dynamic>;
|
|
42
|
-
using MatrixXi32 = Eigen::Matrix<int32_t, Eigen::Dynamic, Eigen::Dynamic>;
|
|
43
41
|
|
|
44
42
|
cls.def(nb::init<>(), DOC(slp, VariableMatrix, VariableMatrix));
|
|
45
43
|
cls.def(nb::init<int>(), "rows"_a,
|
|
@@ -72,13 +70,15 @@ void bind_variable_matrix(nb::module_& autodiff,
|
|
|
72
70
|
"values"_a, DOC(slp, VariableMatrix, set_value));
|
|
73
71
|
cls.def(
|
|
74
72
|
"set_value",
|
|
75
|
-
[](VariableMatrix<double>& self,
|
|
73
|
+
[](VariableMatrix<double>& self,
|
|
74
|
+
nb::DRef<Eigen::MatrixX<int64_t>> values) {
|
|
76
75
|
self.set_value(values.cast<double>());
|
|
77
76
|
},
|
|
78
77
|
"values"_a, DOC(slp, VariableMatrix, set_value));
|
|
79
78
|
cls.def(
|
|
80
79
|
"set_value",
|
|
81
|
-
[](VariableMatrix<double>& self,
|
|
80
|
+
[](VariableMatrix<double>& self,
|
|
81
|
+
nb::DRef<Eigen::MatrixX<int32_t>> values) {
|
|
82
82
|
self.set_value(values.cast<double>());
|
|
83
83
|
},
|
|
84
84
|
"values"_a, DOC(slp, VariableMatrix, set_value));
|
|
@@ -32,8 +32,7 @@ std::optional<T> try_cast(const nb::object& obj) {
|
|
|
32
32
|
/// @tparam Scalar The Eigen matrix's scalar type.
|
|
33
33
|
/// @param obj The nb::ndarray.
|
|
34
34
|
template <typename Scalar>
|
|
35
|
-
std::optional<Eigen::
|
|
36
|
-
try_cast_to_eigen(const nb::object& obj) {
|
|
35
|
+
std::optional<Eigen::MatrixX<Scalar>> try_cast_to_eigen(const nb::object& obj) {
|
|
37
36
|
if (nb::isinstance<nb::ndarray<Scalar>>(obj)) {
|
|
38
37
|
auto arr = nb::cast<nb::ndarray<Scalar>>(obj);
|
|
39
38
|
slp_assert(arr.ndim() == 2);
|
|
@@ -8,4 +8,4 @@ template SLEIPNIR_DLLEXPORT slp::ExitStatus slp::newton(
|
|
|
8
8
|
const NewtonMatrixCallbacks<double>& matrix_callbacks,
|
|
9
9
|
std::span<std::function<bool(const IterationInfo<double>& info)>>
|
|
10
10
|
iteration_callbacks,
|
|
11
|
-
const Options<double>& options, Eigen::
|
|
11
|
+
const Options<double>& options, Eigen::VectorX<double>& x);
|
|
@@ -8,5 +8,4 @@ template SLEIPNIR_DLLEXPORT slp::ExitStatus slp::sqp(
|
|
|
8
8
|
const SQPMatrixCallbacks<double>& matrix_callbacks,
|
|
9
9
|
std::span<std::function<bool(const IterationInfo<double>& info)>>
|
|
10
10
|
iteration_callbacks,
|
|
11
|
-
const slp::Options<double>& options,
|
|
12
|
-
Eigen::Vector<double, Eigen::Dynamic>& x);
|
|
11
|
+
const slp::Options<double>& options, Eigen::VectorX<double>& x);
|
{sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/CMakeLists.txt
RENAMED
|
File without changes
|
{sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/LICENSE.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/pyproject.toml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{sleipnirgroup_jormungandr-0.6.7.dev114 → sleipnirgroup_jormungandr-0.6.7.dev115}/src/util/pool.cpp
RENAMED
|
File without changes
|