casadi 3.6.5__cp39-none-macosx_11_0_arm64.whl → 3.6.7__cp39-none-macosx_11_0_arm64.whl
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.
- casadi/_casadi.so +0 -0
- casadi/casadi-cli +0 -0
- casadi/casadi.py +739 -308
- casadi/cbc +0 -0
- casadi/clp +0 -0
- casadi/cmake/casadi-config-version.cmake +1 -1
- casadi/cmake/casadi-targets.cmake +10 -6
- casadi/cmake/highs/highs-config.cmake +6 -13
- casadi/cmake/highs/highs-targets-release.cmake +13 -13
- casadi/cmake/highs/highs-targets.cmake +25 -22
- casadi/cmake/osqp/osqp-targets.cmake +10 -6
- casadi/cmake/proxsuite/proxsuiteConfigVersion.cmake +0 -5
- casadi/cmake/proxsuite/proxsuiteTargets.cmake +12 -12
- casadi/cmake/qdldl/qdldl-targets.cmake +10 -6
- casadi/cmake/sleqp/sleqp-config-version.cmake +0 -5
- casadi/cmake/sleqp/sleqp-targets.cmake +10 -6
- casadi/cmake/trlib/trlib-config-release.cmake +1 -1
- casadi/cmake/trlib/trlib-config-version.cmake +0 -5
- casadi/cmake/trlib/trlib-config.cmake +12 -12
- casadi/highs +0 -0
- casadi/include/casadi/casadi.i +3 -0
- casadi/include/casadi/casadi_c.h +2 -0
- casadi/include/casadi/config.h +9 -9
- casadi/include/casadi/core/casadi_common.hpp +1 -0
- casadi/include/casadi/core/casadi_export.h +1 -0
- casadi/include/casadi/core/casadi_misc.hpp +52 -0
- casadi/include/casadi/core/casadi_types.hpp +3 -2
- casadi/include/casadi/core/code_generator.hpp +30 -1
- casadi/include/casadi/core/global_options.hpp +2 -0
- casadi/include/casadi/core/mx.hpp +18 -3
- casadi/include/casadi/core/optistack.hpp +23 -0
- casadi/include/casadi/core/runtime/casadi_nlp.hpp +19 -4
- casadi/include/casadi/core/runtime/casadi_ocp_block.hpp +55 -0
- casadi/include/casadi/core/runtime/casadi_oracle.hpp +44 -0
- casadi/include/casadi/core/runtime/casadi_oracle_callback.hpp +39 -0
- casadi/include/casadi/core/runtime/casadi_runtime.hpp +4 -1
- casadi/include/casadi/core/runtime/casadi_scaled_copy.hpp +31 -0
- casadi/include/casadi/core/serializing_stream.hpp +2 -2
- casadi/include/casadi/core/sparsity.hpp +7 -0
- casadi/include/casadi/doc.i +1513 -1016
- casadi/include/casadi/doc_merged.i +965 -719
- casadi/include/casadi/mem.h +1 -0
- casadi/include/daqp/api.h +46 -0
- casadi/include/daqp/auxiliary.h +29 -0
- casadi/include/daqp/bnb.h +32 -0
- casadi/include/daqp/codegen.h +18 -0
- casadi/include/daqp/constants.h +92 -0
- casadi/include/daqp/daqp.h +22 -0
- casadi/include/daqp/daqp_prox.h +18 -0
- casadi/include/daqp/factorization.h +18 -0
- casadi/include/daqp/types.h +161 -0
- casadi/include/daqp/utils.h +44 -0
- casadi/include/fatrop/auxiliary/Common.hpp +34 -0
- casadi/include/fatrop/auxiliary/DynamicLib.hpp +34 -0
- casadi/include/fatrop/auxiliary/FatropOptions.hpp +68 -0
- casadi/include/fatrop/auxiliary/FatropVector.hpp +143 -0
- casadi/include/fatrop/auxiliary/LinearAlgebra.hpp +88 -0
- casadi/include/fatrop/auxiliary/VectorUtils.hpp +54 -0
- casadi/include/fatrop/blasfeo_wrapper/LinearAlgebraBlasfeo.hpp +493 -0
- casadi/include/fatrop/fatrop.hpp +39 -0
- casadi/include/fatrop/function_evaluation/CasadiCodegen.hpp +104 -0
- casadi/include/fatrop/function_evaluation/FunctionEvaluation.hpp +60 -0
- casadi/include/fatrop/json/json.h +946 -0
- casadi/include/fatrop/ocp/CasadiCApiUserdataWrap.hpp +87 -0
- casadi/include/fatrop/ocp/DuInfEvaluator.hpp +38 -0
- casadi/include/fatrop/ocp/FatropOCP.hpp +161 -0
- casadi/include/fatrop/ocp/FatropOCPBuilder.hpp +52 -0
- casadi/include/fatrop/ocp/FatropOCPResto.hpp +299 -0
- casadi/include/fatrop/ocp/OCP.hpp +82 -0
- casadi/include/fatrop/ocp/OCPAbstract.hpp +254 -0
- casadi/include/fatrop/ocp/OCPAdapter.hpp +197 -0
- casadi/include/fatrop/ocp/OCPCInterface.h +289 -0
- casadi/include/fatrop/ocp/OCPDims.hpp +60 -0
- casadi/include/fatrop/ocp/OCPInitializer.hpp +41 -0
- casadi/include/fatrop/ocp/OCPKKT.hpp +69 -0
- casadi/include/fatrop/ocp/OCPLSRiccati.hpp +198 -0
- casadi/include/fatrop/ocp/OCPLSScaler.hpp +66 -0
- casadi/include/fatrop/ocp/OCPLinearSolver.hpp +75 -0
- casadi/include/fatrop/ocp/OCPNoScaling.hpp +42 -0
- casadi/include/fatrop/ocp/OCPScalingMethod.hpp +42 -0
- casadi/include/fatrop/ocp/StageOCP.hpp +592 -0
- casadi/include/fatrop/ocp/StageOCPApplication.hpp +242 -0
- casadi/include/fatrop/ocp/StageOCPExpressions.hpp +182 -0
- casadi/include/fatrop/ocp/UStageEvalAbstract.hpp +168 -0
- casadi/include/fatrop/ocp/UStageOCPImpl.hpp +152 -0
- casadi/include/fatrop/quasi_newton/bfgs.hpp +159 -0
- casadi/include/fatrop/solver/AlgBuilder.hpp +76 -0
- casadi/include/fatrop/solver/AlgStrategy.hpp +33 -0
- casadi/include/fatrop/solver/FatropAlg.hpp +121 -0
- casadi/include/fatrop/solver/FatropData.hpp +188 -0
- casadi/include/fatrop/solver/FatropOptions.hpp +95 -0
- casadi/include/fatrop/solver/FatropPrinter.hpp +65 -0
- casadi/include/fatrop/solver/FatropStats.hpp +63 -0
- casadi/include/fatrop/solver/Filter.hpp +54 -0
- casadi/include/fatrop/solver/IterationData.hpp +56 -0
- casadi/include/fatrop/solver/LineSearch.hpp +86 -0
- casadi/include/fatrop/solver/NLPL1.hpp +263 -0
- casadi/include/fatrop/templates/NLPAlg.hpp +104 -0
- casadi/include/highs/HConfig.h +8 -7
- casadi/include/highs/Highs.h +93 -23
- casadi/include/highs/filereaderlp/def.hpp +19 -0
- casadi/include/highs/interfaces/highs_c_api.h +200 -24
- casadi/include/highs/io/Filereader.h +1 -1
- casadi/include/highs/io/FilereaderEms.h +1 -1
- casadi/include/highs/io/FilereaderLp.h +1 -1
- casadi/include/highs/io/FilereaderMps.h +1 -1
- casadi/include/highs/io/HMPSIO.h +1 -1
- casadi/include/highs/io/HMpsFF.h +5 -3
- casadi/include/highs/io/HighsIO.h +18 -8
- casadi/include/highs/io/LoadOptions.h +1 -1
- casadi/include/highs/ipm/IpxSolution.h +35 -0
- casadi/include/highs/ipm/IpxWrapper.h +1 -1
- casadi/include/highs/ipm/basiclu/basiclu.h +161 -0
- casadi/include/highs/ipm/basiclu/basiclu_factorize.h +247 -0
- casadi/include/highs/ipm/basiclu/basiclu_get_factors.h +108 -0
- casadi/include/highs/ipm/basiclu/basiclu_initialize.h +119 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_factorize.h +34 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_free.h +19 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_get_factors.h +34 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_initialize.h +46 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_solve_dense.h +29 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_solve_for_update.h +42 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_solve_sparse.h +32 -0
- casadi/include/highs/ipm/basiclu/basiclu_obj_update.h +31 -0
- casadi/include/highs/ipm/basiclu/basiclu_object.h +30 -0
- casadi/include/highs/ipm/basiclu/basiclu_solve_dense.h +75 -0
- casadi/include/highs/ipm/basiclu/basiclu_solve_for_update.h +169 -0
- casadi/include/highs/ipm/basiclu/basiclu_solve_sparse.h +112 -0
- casadi/include/highs/ipm/basiclu/basiclu_update.h +125 -0
- casadi/include/highs/ipm/basiclu/lu_def.h +39 -0
- casadi/include/highs/ipm/basiclu/lu_file.h +21 -0
- casadi/include/highs/ipm/basiclu/lu_internal.h +220 -0
- casadi/include/highs/ipm/basiclu/lu_list.h +168 -0
- casadi/include/highs/ipm/ipx/basiclu_kernel.h +20 -0
- casadi/include/highs/ipm/ipx/basiclu_wrapper.h +47 -0
- casadi/include/highs/ipm/ipx/basis.h +351 -0
- casadi/include/highs/ipm/ipx/conjugate_residuals.h +74 -0
- casadi/include/highs/ipm/ipx/control.h +163 -0
- casadi/include/highs/ipm/ipx/crossover.h +157 -0
- casadi/include/highs/ipm/ipx/diagonal_precond.h +45 -0
- casadi/include/highs/ipm/ipx/forrest_tomlin.h +102 -0
- casadi/include/highs/ipm/ipx/guess_basis.h +21 -0
- casadi/include/highs/ipm/ipx/indexed_vector.h +113 -0
- casadi/include/highs/ipm/ipx/info.h +27 -0
- casadi/include/highs/ipm/ipx/ipm.h +94 -0
- casadi/include/highs/ipm/ipx/ipx_c.h +47 -0
- casadi/include/highs/ipm/ipx/ipx_config.h +9 -0
- casadi/include/highs/ipm/ipx/ipx_info.h +111 -0
- casadi/include/highs/ipm/ipx/ipx_internal.h +88 -0
- casadi/include/highs/ipm/ipx/ipx_parameters.h +75 -0
- casadi/include/highs/ipm/ipx/ipx_status.h +57 -0
- casadi/include/highs/ipm/ipx/iterate.h +328 -0
- casadi/include/highs/ipm/ipx/kkt_solver.h +70 -0
- casadi/include/highs/ipm/ipx/kkt_solver_basis.h +66 -0
- casadi/include/highs/ipm/ipx/kkt_solver_diag.h +48 -0
- casadi/include/highs/ipm/ipx/linear_operator.h +26 -0
- casadi/include/highs/ipm/ipx/lp_solver.h +201 -0
- casadi/include/highs/ipm/ipx/lu_factorization.h +79 -0
- casadi/include/highs/ipm/ipx/lu_update.h +129 -0
- casadi/include/highs/ipm/ipx/maxvolume.h +54 -0
- casadi/include/highs/ipm/ipx/model.h +409 -0
- casadi/include/highs/ipm/ipx/multistream.h +52 -0
- casadi/include/highs/ipm/ipx/normal_matrix.h +44 -0
- casadi/include/highs/ipm/ipx/power_method.h +44 -0
- casadi/include/highs/ipm/ipx/sparse_matrix.h +195 -0
- casadi/include/highs/ipm/ipx/sparse_utils.h +58 -0
- casadi/include/highs/ipm/ipx/splitted_normal_matrix.h +63 -0
- casadi/include/highs/ipm/ipx/starting_basis.h +39 -0
- casadi/include/highs/ipm/ipx/symbolic_invert.h +29 -0
- casadi/include/highs/ipm/ipx/timer.h +24 -0
- casadi/include/highs/ipm/ipx/utils.h +39 -0
- casadi/include/highs/lp_data/HConst.h +20 -10
- casadi/include/highs/lp_data/HStruct.h +23 -1
- casadi/include/highs/lp_data/HighsAnalysis.h +1 -1
- casadi/include/highs/lp_data/HighsCallback.h +10 -3
- casadi/include/highs/lp_data/HighsCallbackStruct.h +31 -5
- casadi/include/highs/lp_data/HighsDebug.h +1 -1
- casadi/include/highs/lp_data/HighsInfo.h +20 -2
- casadi/include/highs/lp_data/HighsInfoDebug.h +1 -1
- casadi/include/highs/lp_data/HighsLp.h +17 -1
- casadi/include/highs/lp_data/HighsLpSolverObject.h +1 -1
- casadi/include/highs/lp_data/HighsLpUtils.h +19 -19
- casadi/include/highs/lp_data/HighsModelUtils.h +1 -1
- casadi/include/highs/lp_data/HighsOptions.h +237 -10
- casadi/include/highs/lp_data/HighsRanging.h +1 -1
- casadi/include/highs/lp_data/HighsRuntimeOptions.h +2 -2
- casadi/include/highs/lp_data/HighsSolution.h +2 -2
- casadi/include/highs/lp_data/HighsSolutionDebug.h +1 -1
- casadi/include/highs/lp_data/HighsSolve.h +3 -1
- casadi/include/highs/lp_data/HighsStatus.h +1 -1
- casadi/include/highs/mip/HighsCliqueTable.h +4 -4
- casadi/include/highs/mip/HighsConflictPool.h +1 -1
- casadi/include/highs/mip/HighsCutGeneration.h +1 -1
- casadi/include/highs/mip/HighsCutPool.h +2 -2
- casadi/include/highs/mip/HighsDebugSol.h +22 -29
- casadi/include/highs/mip/HighsDomain.h +10 -2
- casadi/include/highs/mip/HighsDomainChange.h +1 -1
- casadi/include/highs/mip/HighsDynamicRowMatrix.h +5 -3
- casadi/include/highs/mip/HighsGFkSolve.h +3 -3
- casadi/include/highs/mip/HighsImplications.h +3 -3
- casadi/include/highs/mip/HighsLpAggregator.h +1 -1
- casadi/include/highs/mip/HighsLpRelaxation.h +6 -1
- casadi/include/highs/mip/HighsMipSolver.h +4 -2
- casadi/include/highs/mip/HighsMipSolverData.h +47 -4
- casadi/include/highs/mip/HighsModkSeparator.h +2 -2
- casadi/include/highs/mip/HighsNodeQueue.h +5 -3
- casadi/include/highs/mip/HighsObjectiveFunction.h +1 -1
- casadi/include/highs/mip/HighsPathSeparator.h +2 -2
- casadi/include/highs/mip/HighsPrimalHeuristics.h +1 -1
- casadi/include/highs/mip/HighsPseudocost.h +35 -23
- casadi/include/highs/mip/HighsRedcostFixing.h +1 -1
- casadi/include/highs/mip/HighsSearch.h +2 -1
- casadi/include/highs/mip/HighsSeparation.h +1 -1
- casadi/include/highs/mip/HighsSeparator.h +1 -1
- casadi/include/highs/mip/HighsTableauSeparator.h +1 -1
- casadi/include/highs/mip/HighsTransformedLp.h +1 -1
- casadi/include/highs/model/HighsHessian.h +5 -0
- casadi/include/highs/model/HighsHessianUtils.h +2 -0
- casadi/include/highs/model/HighsModel.h +10 -1
- casadi/include/highs/parallel/HighsMutex.h +2 -1
- casadi/include/highs/parallel/HighsParallel.h +7 -2
- casadi/include/highs/parallel/HighsTask.h +1 -2
- casadi/include/highs/pdlp/CupdlpWrapper.h +93 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_cs.h +41 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_defs.h +423 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_linalg.h +183 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_proj.h +19 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_restart.h +31 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_scaling_cuda.h +28 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_solver.h +98 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_step.h +33 -0
- casadi/include/highs/pdlp/cupdlp/cupdlp_utils.c +1726 -0
- casadi/include/highs/pdqsort/pdqsort.h +532 -0
- casadi/include/highs/presolve/HPresolve.h +27 -14
- casadi/include/highs/presolve/HPresolveAnalysis.h +1 -1
- casadi/include/highs/presolve/HighsPostsolveStack.h +92 -68
- casadi/include/highs/presolve/HighsSymmetry.h +6 -5
- casadi/include/highs/presolve/ICrash.h +8 -2
- casadi/include/highs/presolve/ICrashUtil.h +1 -1
- casadi/include/highs/presolve/ICrashX.h +1 -1
- casadi/include/highs/presolve/PresolveComponent.h +1 -1
- casadi/include/highs/qpsolver/a_asm.hpp +23 -12
- casadi/include/highs/qpsolver/a_quass.hpp +8 -1
- casadi/include/highs/qpsolver/basis.hpp +150 -0
- casadi/include/highs/qpsolver/crashsolution.hpp +12 -0
- casadi/include/highs/qpsolver/dantzigpricing.hpp +72 -0
- casadi/include/highs/qpsolver/devexpricing.hpp +99 -0
- casadi/include/highs/qpsolver/eventhandler.hpp +23 -0
- casadi/include/highs/qpsolver/factor.hpp +400 -0
- casadi/include/highs/qpsolver/feasibility_bounded.hpp +105 -0
- casadi/include/highs/qpsolver/feasibility_highs.hpp +270 -0
- casadi/include/highs/qpsolver/gradient.hpp +39 -0
- casadi/include/highs/qpsolver/instance.hpp +63 -0
- casadi/include/highs/qpsolver/matrix.hpp +335 -0
- casadi/include/highs/qpsolver/pricing.hpp +15 -0
- casadi/include/highs/qpsolver/qpconst.hpp +27 -0
- casadi/include/highs/qpsolver/{vector.hpp → qpvector.hpp} +25 -25
- casadi/include/highs/qpsolver/quass.hpp +1 -1
- casadi/include/highs/qpsolver/ratiotest.hpp +19 -0
- casadi/include/highs/qpsolver/runtime.hpp +38 -0
- casadi/include/highs/qpsolver/settings.hpp +57 -0
- casadi/include/highs/qpsolver/snippets.hpp +29 -0
- casadi/include/highs/qpsolver/statistics.hpp +23 -0
- casadi/include/highs/qpsolver/steepestedgepricing.hpp +167 -0
- casadi/include/highs/simplex/HApp.h +1 -1
- casadi/include/highs/simplex/HEkk.h +52 -18
- casadi/include/highs/simplex/HEkkDual.h +1 -1
- casadi/include/highs/simplex/HEkkDualRHS.h +6 -7
- casadi/include/highs/simplex/HEkkDualRow.h +2 -2
- casadi/include/highs/simplex/HEkkPrimal.h +6 -1
- casadi/include/highs/simplex/HSimplex.h +1 -3
- casadi/include/highs/simplex/HSimplexDebug.h +1 -1
- casadi/include/highs/simplex/HSimplexNla.h +1 -1
- casadi/include/highs/simplex/HSimplexReport.h +1 -1
- casadi/include/highs/simplex/HighsSimplexAnalysis.h +228 -100
- casadi/include/highs/simplex/SimplexConst.h +1 -1
- casadi/include/highs/simplex/SimplexStruct.h +2 -2
- casadi/include/highs/simplex/SimplexTimer.h +1 -1
- casadi/include/highs/test/DevKkt.h +1 -1
- casadi/include/highs/test/KktCh2.h +1 -1
- casadi/include/highs/util/FactorTimer.h +1 -1
- casadi/include/highs/util/HFactor.h +35 -6
- casadi/include/highs/util/HFactorConst.h +1 -1
- casadi/include/highs/util/HFactorDebug.h +1 -1
- casadi/include/highs/util/HSet.h +1 -1
- casadi/include/highs/util/HVector.h +1 -1
- casadi/include/highs/util/HVectorBase.h +1 -1
- casadi/include/highs/util/HighsCDouble.h +3 -3
- casadi/include/highs/util/HighsComponent.h +1 -1
- casadi/include/highs/util/HighsDataStack.h +4 -4
- casadi/include/highs/util/HighsDisjointSets.h +1 -1
- casadi/include/highs/util/HighsHash.h +28 -21
- casadi/include/highs/util/HighsHashTree.h +63 -63
- casadi/include/highs/util/HighsInt.h +1 -1
- casadi/include/highs/util/HighsIntegers.h +8 -9
- casadi/include/highs/util/HighsLinearSumBounds.h +1 -1
- casadi/include/highs/util/HighsMatrixPic.h +1 -1
- casadi/include/highs/util/HighsMatrixSlice.h +9 -6
- casadi/include/highs/util/HighsMatrixUtils.h +1 -1
- casadi/include/highs/util/HighsMemoryAllocation.h +55 -0
- casadi/include/highs/util/HighsRandom.h +27 -15
- casadi/include/highs/util/HighsRbTree.h +2 -2
- casadi/include/highs/util/HighsSort.h +7 -7
- casadi/include/highs/util/HighsSparseMatrix.h +5 -2
- casadi/include/highs/util/HighsSparseVectorSum.h +2 -2
- casadi/include/highs/util/HighsSplay.h +1 -1
- casadi/include/highs/util/HighsTimer.h +18 -9
- casadi/include/highs/util/HighsUtils.h +15 -8
- casadi/include/highs/util/stringutil.h +9 -4
- casadi/include/highs/zstr/strict_fstream.hpp +237 -0
- casadi/include/highs/zstr/zstr.hpp +472 -0
- casadi/include/highs_export.h +43 -0
- casadi/include/licenses/daqp-external/LICENSE +21 -0
- casadi/include/licenses/{alpaqa-external/LICENSE → fatrop-external/LICENSE.txt} +2 -2
- casadi/include/licenses/fatrop-external/external/blasfeo/LICENSE.txt +26 -0
- casadi/include/licenses/fatrop-external/external/pybind11/LICENSE +29 -0
- casadi/include/licenses/fatrop-external/misc/license_header.txt +17 -0
- casadi/include/licenses/highs-external/{LICENSE → LICENSE.txt} +1 -1
- casadi/include/osqp/constants.h +2 -3
- casadi/include/osqp/version.h +9 -0
- casadi/include/sleqp/defs.h +4 -4
- casadi/include/sleqp/export.h +1 -0
- casadi/lib/cmake/tinyxml2/tinyxml2-config-version.cmake +0 -5
- casadi/lib/cmake/tinyxml2/tinyxml2-static-targets.cmake +10 -6
- casadi/lib/libtinyxml2.a +0 -0
- casadi/lib/pkgconfig/tinyxml2.pc +1 -1
- casadi/libCbc.3.10.11.dylib +0 -0
- casadi/libCbc.3.dylib +0 -0
- casadi/libCbc.dylib +0 -0
- casadi/libCbc.la +2 -2
- casadi/libCbcSolver.3.10.11.dylib +0 -0
- casadi/libCbcSolver.3.dylib +0 -0
- casadi/libCbcSolver.dylib +0 -0
- casadi/libCbcSolver.la +2 -2
- casadi/libCgl.1.10.8.dylib +0 -0
- casadi/libCgl.1.dylib +0 -0
- casadi/libCgl.dylib +0 -0
- casadi/libCgl.la +2 -2
- casadi/libClp.1.14.9.dylib +0 -0
- casadi/libClp.1.dylib +0 -0
- casadi/libClp.dylib +0 -0
- casadi/libClp.la +2 -2
- casadi/libClpSolver.1.14.9.dylib +0 -0
- casadi/libClpSolver.1.dylib +0 -0
- casadi/libClpSolver.dylib +0 -0
- casadi/libClpSolver.la +2 -2
- casadi/libCoinUtils.3.11.10.dylib +0 -0
- casadi/libCoinUtils.3.dylib +0 -0
- casadi/libCoinUtils.dylib +0 -0
- casadi/libCoinUtils.la +1 -1
- casadi/libOsi.1.13.9.dylib +0 -0
- casadi/libOsi.1.dylib +0 -0
- casadi/libOsi.dylib +0 -0
- casadi/libOsi.la +2 -2
- casadi/libOsiCbc.3.10.11.dylib +0 -0
- casadi/libOsiCbc.3.dylib +0 -0
- casadi/libOsiCbc.dylib +0 -0
- casadi/libOsiCbc.la +2 -2
- casadi/libOsiClp.1.14.9.dylib +0 -0
- casadi/libOsiClp.1.dylib +0 -0
- casadi/libOsiClp.dylib +0 -0
- casadi/libOsiClp.la +2 -2
- casadi/libOsiCommonTests.1.13.9.dylib +0 -0
- casadi/libOsiCommonTests.1.dylib +0 -0
- casadi/libOsiCommonTests.dylib +0 -0
- casadi/libOsiCommonTests.la +2 -2
- casadi/libblasfeo.dylib +0 -0
- casadi/libbonmin.4.8.9.dylib +0 -0
- casadi/libbonmin.4.dylib +0 -0
- casadi/libbonmin.dylib +0 -0
- casadi/libbonmin.la +2 -2
- casadi/libc++.1.0.dylib +0 -0
- casadi/libcasadi.3.7.dylib +0 -0
- casadi/libcasadi.dylib +0 -0
- casadi/libcasadi_conic_cbc.3.7.dylib +0 -0
- casadi/libcasadi_conic_cbc.dylib +0 -0
- casadi/libcasadi_conic_clp.3.7.dylib +0 -0
- casadi/libcasadi_conic_clp.dylib +0 -0
- casadi/libcasadi_conic_cplex.3.7.dylib +0 -0
- casadi/libcasadi_conic_cplex.dylib +0 -0
- casadi/libcasadi_conic_daqp.3.7.dylib +0 -0
- casadi/libcasadi_conic_daqp.dylib +0 -0
- casadi/libcasadi_conic_fatrop.3.7.dylib +0 -0
- casadi/libcasadi_conic_fatrop.dylib +0 -0
- casadi/libcasadi_conic_gurobi.3.7.dylib +0 -0
- casadi/libcasadi_conic_gurobi.dylib +0 -0
- casadi/libcasadi_conic_highs.3.7.dylib +0 -0
- casadi/libcasadi_conic_highs.dylib +0 -0
- casadi/libcasadi_conic_ipqp.3.7.dylib +0 -0
- casadi/libcasadi_conic_ipqp.dylib +0 -0
- casadi/libcasadi_conic_nlpsol.3.7.dylib +0 -0
- casadi/libcasadi_conic_nlpsol.dylib +0 -0
- casadi/libcasadi_conic_osqp.3.7.dylib +0 -0
- casadi/libcasadi_conic_osqp.dylib +0 -0
- casadi/libcasadi_conic_proxqp.3.7.dylib +0 -0
- casadi/libcasadi_conic_proxqp.dylib +0 -0
- casadi/libcasadi_conic_qpoases.3.7.dylib +0 -0
- casadi/libcasadi_conic_qpoases.dylib +0 -0
- casadi/libcasadi_conic_qrqp.3.7.dylib +0 -0
- casadi/libcasadi_conic_qrqp.dylib +0 -0
- casadi/libcasadi_conic_superscs.3.7.dylib +0 -0
- casadi/libcasadi_conic_superscs.dylib +0 -0
- casadi/libcasadi_importer_shell.3.7.dylib +0 -0
- casadi/libcasadi_importer_shell.dylib +0 -0
- casadi/libcasadi_integrator_collocation.3.7.dylib +0 -0
- casadi/libcasadi_integrator_collocation.dylib +0 -0
- casadi/libcasadi_integrator_cvodes.3.7.dylib +0 -0
- casadi/libcasadi_integrator_cvodes.dylib +0 -0
- casadi/libcasadi_integrator_idas.3.7.dylib +0 -0
- casadi/libcasadi_integrator_idas.dylib +0 -0
- casadi/libcasadi_integrator_rk.3.7.dylib +0 -0
- casadi/libcasadi_integrator_rk.dylib +0 -0
- casadi/libcasadi_interpolant_bspline.3.7.dylib +0 -0
- casadi/libcasadi_interpolant_bspline.dylib +0 -0
- casadi/libcasadi_interpolant_linear.3.7.dylib +0 -0
- casadi/libcasadi_interpolant_linear.dylib +0 -0
- casadi/libcasadi_linsol_csparse.3.7.dylib +0 -0
- casadi/libcasadi_linsol_csparse.dylib +0 -0
- casadi/libcasadi_linsol_csparsecholesky.3.7.dylib +0 -0
- casadi/libcasadi_linsol_csparsecholesky.dylib +0 -0
- casadi/libcasadi_linsol_lapacklu.3.7.dylib +0 -0
- casadi/libcasadi_linsol_lapacklu.dylib +0 -0
- casadi/libcasadi_linsol_lapackqr.3.7.dylib +0 -0
- casadi/libcasadi_linsol_lapackqr.dylib +0 -0
- casadi/libcasadi_linsol_ldl.3.7.dylib +0 -0
- casadi/libcasadi_linsol_ldl.dylib +0 -0
- casadi/libcasadi_linsol_lsqr.3.7.dylib +0 -0
- casadi/libcasadi_linsol_lsqr.dylib +0 -0
- casadi/libcasadi_linsol_ma27.3.7.dylib +0 -0
- casadi/libcasadi_linsol_ma27.dylib +0 -0
- casadi/libcasadi_linsol_mumps.3.7.dylib +0 -0
- casadi/libcasadi_linsol_mumps.dylib +0 -0
- casadi/libcasadi_linsol_qr.3.7.dylib +0 -0
- casadi/libcasadi_linsol_qr.dylib +0 -0
- casadi/libcasadi_linsol_symbolicqr.3.7.dylib +0 -0
- casadi/libcasadi_linsol_symbolicqr.dylib +0 -0
- casadi/libcasadi_linsol_tridiag.3.7.dylib +0 -0
- casadi/libcasadi_linsol_tridiag.dylib +0 -0
- casadi/libcasadi_nlpsol_ampl.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_ampl.dylib +0 -0
- casadi/libcasadi_nlpsol_blocksqp.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_blocksqp.dylib +0 -0
- casadi/libcasadi_nlpsol_bonmin.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_bonmin.dylib +0 -0
- casadi/libcasadi_nlpsol_fatrop.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_fatrop.dylib +0 -0
- casadi/libcasadi_nlpsol_feasiblesqpmethod.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_feasiblesqpmethod.dylib +0 -0
- casadi/libcasadi_nlpsol_ipopt.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_ipopt.dylib +0 -0
- casadi/libcasadi_nlpsol_knitro.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_knitro.dylib +0 -0
- casadi/libcasadi_nlpsol_madnlp.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_madnlp.dylib +0 -0
- casadi/libcasadi_nlpsol_qrsqp.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_qrsqp.dylib +0 -0
- casadi/libcasadi_nlpsol_scpgen.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_scpgen.dylib +0 -0
- casadi/libcasadi_nlpsol_sleqp.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_sleqp.dylib +0 -0
- casadi/libcasadi_nlpsol_snopt.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_snopt.dylib +0 -0
- casadi/libcasadi_nlpsol_sqpmethod.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_sqpmethod.dylib +0 -0
- casadi/libcasadi_rootfinder_fast_newton.3.7.dylib +0 -0
- casadi/libcasadi_rootfinder_fast_newton.dylib +0 -0
- casadi/libcasadi_rootfinder_kinsol.3.7.dylib +0 -0
- casadi/libcasadi_rootfinder_kinsol.dylib +0 -0
- casadi/libcasadi_rootfinder_newton.3.7.dylib +0 -0
- casadi/libcasadi_rootfinder_newton.dylib +0 -0
- casadi/libcasadi_rootfinder_nlpsol.3.7.dylib +0 -0
- casadi/libcasadi_rootfinder_nlpsol.dylib +0 -0
- casadi/libcasadi_sundials_common.3.7.dylib +0 -0
- casadi/libcasadi_sundials_common.dylib +0 -0
- casadi/libcasadi_xmlfile_tinyxml.3.7.dylib +0 -0
- casadi/libcasadi_xmlfile_tinyxml.dylib +0 -0
- casadi/libcoinmetis.2.dylib +0 -0
- casadi/libcoinmetis.dylib +0 -0
- casadi/libcoinmetis.la +1 -1
- casadi/libcoinmumps.3.dylib +0 -0
- casadi/libcoinmumps.dylib +0 -0
- casadi/libcoinmumps.la +2 -2
- casadi/libcplex_adaptor.dylib +0 -0
- casadi/{libamd.3.0.3.dylib → libdaqp.dylib} +0 -0
- casadi/libdaqpstat.a +0 -0
- casadi/libfatrop.dylib +0 -0
- casadi/libgcc_s.1.1.dylib +0 -0
- casadi/libgfortran.5.dylib +0 -0
- casadi/libgurobi_adaptor.dylib +0 -0
- casadi/libhighs.1.7.dylib +0 -0
- casadi/libhighs.1.dylib +0 -0
- casadi/libhighs.dylib +0 -0
- casadi/libindirect.a +0 -0
- casadi/libipopt.3.dylib +0 -0
- casadi/libipopt.dylib +0 -0
- casadi/libipopt.la +2 -2
- casadi/liblinsys.a +0 -0
- casadi/{libsuitesparseconfig.7.0.1.dylib → libmatlab_ipc.dylib} +0 -0
- casadi/libosqp.a +0 -0
- casadi/libosqp.dylib +0 -0
- casadi/libqdldl.a +0 -0
- casadi/libqdldl.dylib +0 -0
- casadi/libquadmath.0.dylib +0 -0
- casadi/libsipopt.3.dylib +0 -0
- casadi/libsipopt.dylib +0 -0
- casadi/libsipopt.la +2 -2
- casadi/libsleqp.1.0.1.dylib +0 -0
- casadi/libsleqp.dylib +0 -0
- casadi/libsuperscs.a +0 -0
- casadi/libtrlib.0.4.dylib +0 -0
- casadi/libtrlib.dylib +0 -0
- casadi/libz.1.2.13.dylib +0 -0
- casadi/pkgconfig/bonmin.pc +1 -1
- casadi/pkgconfig/casadi.pc +5 -5
- casadi/pkgconfig/cbc.pc +1 -1
- casadi/pkgconfig/cgl.pc +1 -1
- casadi/pkgconfig/clp.pc +1 -1
- casadi/pkgconfig/coinmetis.pc +1 -1
- casadi/pkgconfig/coinmumps.pc +2 -2
- casadi/pkgconfig/coinutils.pc +2 -2
- casadi/pkgconfig/highs.pc +4 -4
- casadi/pkgconfig/ipopt.pc +2 -2
- casadi/pkgconfig/osi-cbc.pc +1 -1
- casadi/pkgconfig/osi-clp.pc +1 -1
- casadi/pkgconfig/osi-unittests.pc +1 -1
- casadi/pkgconfig/osi.pc +1 -1
- casadi/pkgconfig/sleqp.pc +1 -1
- casadi/tools/__init__.py +4 -0
- casadi/tools/bounds.py +3 -3
- {casadi-3.6.5.dist-info → casadi-3.6.7.dist-info}/METADATA +2 -2
- {casadi-3.6.5.dist-info → casadi-3.6.7.dist-info}/RECORD +532 -477
- casadi/cmake/alpaqa/alpaqaConfig.cmake +0 -24
- casadi/cmake/alpaqa/alpaqaConfigVersion.cmake +0 -70
- casadi/cmake/alpaqa/alpaqaTargets-release.cmake +0 -19
- casadi/cmake/alpaqa/alpaqaTargets.cmake +0 -116
- casadi/include/alpaqa/accelerators/anderson.hpp +0 -133
- casadi/include/alpaqa/accelerators/internal/anderson-helpers.hpp +0 -92
- casadi/include/alpaqa/accelerators/internal/limited-memory-qr.hpp +0 -295
- casadi/include/alpaqa/accelerators/lbfgs.hpp +0 -244
- casadi/include/alpaqa/accelerators/steihaugcg.hpp +0 -143
- casadi/include/alpaqa/alpaqa.hpp +0 -3
- casadi/include/alpaqa/casadi/CasADiControlProblem.hpp +0 -185
- casadi/include/alpaqa/casadi/CasADiFunctionWrapper.hpp +0 -104
- casadi/include/alpaqa/casadi/CasADiProblem.hpp +0 -102
- casadi/include/alpaqa/casadi-loader-export.hpp +0 -15
- casadi/include/alpaqa/casadi-ocp-loader-export.hpp +0 -15
- casadi/include/alpaqa/config/config.hpp +0 -165
- casadi/include/alpaqa/dl/dl-problem.h +0 -476
- casadi/include/alpaqa/dl/dl-problem.hpp +0 -301
- casadi/include/alpaqa/export.h +0 -42
- casadi/include/alpaqa/export.hpp +0 -30
- casadi/include/alpaqa/implementation/accelerators/lbfgs.tpp +0 -240
- casadi/include/alpaqa/implementation/casadi/CasADiControlProblem.tpp +0 -594
- casadi/include/alpaqa/implementation/casadi/CasADiLoader-util.hpp +0 -50
- casadi/include/alpaqa/implementation/casadi/CasADiProblem.tpp +0 -425
- casadi/include/alpaqa/implementation/inner/directions/panoc/structured-lbfgs.tpp +0 -164
- casadi/include/alpaqa/implementation/inner/panoc-helpers.tpp +0 -389
- casadi/include/alpaqa/implementation/inner/panoc-ocp.tpp +0 -798
- casadi/include/alpaqa/implementation/inner/panoc.tpp +0 -448
- casadi/include/alpaqa/implementation/inner/pantr.tpp +0 -474
- casadi/include/alpaqa/implementation/inner/zerofpr.tpp +0 -482
- casadi/include/alpaqa/implementation/outer/alm.tpp +0 -228
- casadi/include/alpaqa/implementation/outer/internal/alm-helpers.tpp +0 -80
- casadi/include/alpaqa/implementation/params/params.tpp +0 -158
- casadi/include/alpaqa/implementation/problem/ocproblem.tpp +0 -56
- casadi/include/alpaqa/implementation/problem/type-erased-problem.tpp +0 -211
- casadi/include/alpaqa/implementation/util/io/csv.tpp +0 -120
- casadi/include/alpaqa/implementation/util/print.tpp +0 -151
- casadi/include/alpaqa/inner/directions/panoc/anderson.hpp +0 -98
- casadi/include/alpaqa/inner/directions/panoc/lbfgs.hpp +0 -94
- casadi/include/alpaqa/inner/directions/panoc/structured-lbfgs.hpp +0 -146
- casadi/include/alpaqa/inner/directions/panoc/structured-newton.hpp +0 -264
- casadi/include/alpaqa/inner/directions/panoc-direction-update.hpp +0 -96
- casadi/include/alpaqa/inner/directions/panoc-ocp/lqr.hpp +0 -181
- casadi/include/alpaqa/inner/directions/panoc-ocp/ocp-vars.hpp +0 -492
- casadi/include/alpaqa/inner/directions/pantr/newton-tr.hpp +0 -192
- casadi/include/alpaqa/inner/directions/pantr/pantr-direction.hpp +0 -99
- casadi/include/alpaqa/inner/inner-solve-options.hpp +0 -30
- casadi/include/alpaqa/inner/internal/lipschitz.hpp +0 -27
- casadi/include/alpaqa/inner/internal/panoc-helpers.hpp +0 -10
- casadi/include/alpaqa/inner/internal/panoc-stop-crit.hpp +0 -124
- casadi/include/alpaqa/inner/internal/solverstatus.hpp +0 -42
- casadi/include/alpaqa/inner/panoc-ocp.hpp +0 -302
- casadi/include/alpaqa/inner/panoc.hpp +0 -274
- casadi/include/alpaqa/inner/pantr.hpp +0 -284
- casadi/include/alpaqa/inner/zerofpr.hpp +0 -274
- casadi/include/alpaqa/ipopt/ipopt-adapter.hpp +0 -81
- casadi/include/alpaqa/ipopt/ipopt-enums.hpp +0 -35
- casadi/include/alpaqa/lbfgsb/lbfgsb-adapter.hpp +0 -111
- casadi/include/alpaqa/newton-tr-pantr-alm.hpp +0 -27
- casadi/include/alpaqa/outer/alm.hpp +0 -190
- casadi/include/alpaqa/outer/internal/alm-helpers.hpp +0 -10
- casadi/include/alpaqa/panoc-alm.hpp +0 -27
- casadi/include/alpaqa/panoc-anderson-alm.hpp +0 -27
- casadi/include/alpaqa/params/params.hpp +0 -60
- casadi/include/alpaqa/problem/box-constr-problem.hpp +0 -220
- casadi/include/alpaqa/problem/box.hpp +0 -82
- casadi/include/alpaqa/problem/functional-problem.hpp +0 -73
- casadi/include/alpaqa/problem/kkt-error.hpp +0 -43
- casadi/include/alpaqa/problem/ocproblem-counters.hpp +0 -116
- casadi/include/alpaqa/problem/ocproblem.hpp +0 -662
- casadi/include/alpaqa/problem/problem-counters.hpp +0 -116
- casadi/include/alpaqa/problem/problem-with-counters.hpp +0 -141
- casadi/include/alpaqa/problem/type-erased-problem.hpp +0 -874
- casadi/include/alpaqa/problem/unconstr-problem.hpp +0 -37
- casadi/include/alpaqa/structured-panoc-alm.hpp +0 -27
- casadi/include/alpaqa/structured-zerofpr-alm.hpp +0 -27
- casadi/include/alpaqa/util/alloc-check.hpp +0 -23
- casadi/include/alpaqa/util/atomic-stop-signal.hpp +0 -24
- casadi/include/alpaqa/util/check-dim.hpp +0 -64
- casadi/include/alpaqa/util/copyable_unique_ptr.hpp +0 -32
- casadi/include/alpaqa/util/demangled-typename.hpp +0 -9
- casadi/include/alpaqa/util/enumerate.hpp +0 -70
- casadi/include/alpaqa/util/float.hpp +0 -25
- casadi/include/alpaqa/util/index-set.hpp +0 -97
- casadi/include/alpaqa/util/io/csv.hpp +0 -43
- casadi/include/alpaqa/util/iter-adapter.hpp +0 -68
- casadi/include/alpaqa/util/max-history.hpp +0 -47
- casadi/include/alpaqa/util/noop-delete.hpp +0 -15
- casadi/include/alpaqa/util/not-implemented.hpp +0 -12
- casadi/include/alpaqa/util/print.hpp +0 -78
- casadi/include/alpaqa/util/quadmath/quadmath-print.hpp +0 -20
- casadi/include/alpaqa/util/quadmath/quadmath.hpp +0 -137
- casadi/include/alpaqa/util/required-method.hpp +0 -29
- casadi/include/alpaqa/util/ringbuffer.hpp +0 -212
- casadi/include/alpaqa/util/set-intersection.hpp +0 -129
- casadi/include/alpaqa/util/sparse-ops.hpp +0 -164
- casadi/include/alpaqa/util/timed.hpp +0 -22
- casadi/include/alpaqa/util/type-erasure.hpp +0 -568
- casadi/include/alpaqa/util/type-traits.hpp +0 -58
- casadi/include/alpaqa/zerofpr-alm.hpp +0 -27
- casadi/include/alpaqa/zerofpr-anderson-alm.hpp +0 -27
- casadi/include/alpaqa-version.h +0 -8
- casadi/include/highs/fortran/highs_fortran_api.mod +0 -0
- casadi/include/licenses/alpaqa-external/src/thirdparty/lbfgsb/Lbfgsb.3.0/License.txt +0 -71
- casadi/libFortranHighs.dylib +0 -0
- casadi/libalpaqa.1.0.0.dylib +0 -0
- casadi/libalpaqa.dylib +0 -0
- casadi/libcamd.3.0.3.dylib +0 -0
- casadi/libcasadi_nlpsol_alpaqa.3.7.dylib +0 -0
- casadi/libcasadi_nlpsol_alpaqa.dylib +0 -0
- casadi/libccolamd.3.0.3.dylib +0 -0
- casadi/libcholmod.4.0.3.dylib +0 -0
- casadi/libcholmod_cuda.4.0.3.dylib +0 -0
- casadi/libcolamd.3.0.3.dylib +0 -0
- casadi/libhighs.1.6.0.dylib +0 -0
- casadi/libhighs.1.6.dylib +0 -0
- casadi/libumfpack.6.1.0.dylib +0 -0
- {casadi-3.6.5.dist-info → casadi-3.6.7.dist-info}/WHEEL +0 -0
@@ -144,6 +144,28 @@ private:
|
|
144
144
|
template<typename T>
|
145
145
|
std::vector<T> vector_slice(const std::vector<T> &v, const std::vector<casadi_int> &i);
|
146
146
|
|
147
|
+
/** \brief Select subset of vector
|
148
|
+
|
149
|
+
* \param v Vector to slice
|
150
|
+
* \param s Select?
|
151
|
+
|
152
|
+
\identifier{286} */
|
153
|
+
template<typename T>
|
154
|
+
std::vector<T> vector_select(const std::vector<T> &v, const std::vector<bool> &s,
|
155
|
+
bool invert=false);
|
156
|
+
|
157
|
+
/** \brief Return all but the first element of a vector
|
158
|
+
|
159
|
+
\identifier{27y} */
|
160
|
+
template<typename T>
|
161
|
+
std::vector<T> vector_tail(const std::vector<T> &v);
|
162
|
+
|
163
|
+
/** \brief Return all but the last element of a vector
|
164
|
+
|
165
|
+
\identifier{285} */
|
166
|
+
template<typename T>
|
167
|
+
std::vector<T> vector_init(const std::vector<T> &v);
|
168
|
+
|
147
169
|
/** \brief Reverse a list
|
148
170
|
|
149
171
|
\identifier{1la} */
|
@@ -526,6 +548,36 @@ namespace casadi {
|
|
526
548
|
return ret;
|
527
549
|
}
|
528
550
|
|
551
|
+
template<typename T>
|
552
|
+
std::vector<T> vector_select(const std::vector<T> &v, const std::vector<bool> &s, bool invert) {
|
553
|
+
std::vector<T> ret;
|
554
|
+
casadi_assert(v.size()==s.size(), "Dimension mismatch.");
|
555
|
+
if (invert) {
|
556
|
+
for (casadi_int k=0;k<s.size();++k) {
|
557
|
+
if (!s[k]) ret.push_back(v[k]);
|
558
|
+
}
|
559
|
+
} else {
|
560
|
+
for (casadi_int k=0;k<s.size();++k) {
|
561
|
+
if (s[k]) ret.push_back(v[k]);
|
562
|
+
}
|
563
|
+
}
|
564
|
+
return ret;
|
565
|
+
}
|
566
|
+
|
567
|
+
template<typename T>
|
568
|
+
std::vector<T> vector_tail(const std::vector<T> &v) {
|
569
|
+
std::vector<T> ret;
|
570
|
+
ret.insert(ret.begin(), v.begin()+1, v.end());
|
571
|
+
return ret;
|
572
|
+
}
|
573
|
+
|
574
|
+
template<typename T>
|
575
|
+
std::vector<T> vector_init(const std::vector<T> &v) {
|
576
|
+
std::vector<T> ret;
|
577
|
+
ret.insert(ret.begin(), v.begin(), v.begin()+v.size()-1);
|
578
|
+
return ret;
|
579
|
+
}
|
580
|
+
|
529
581
|
template<typename T>
|
530
582
|
std::vector<T> reverse(const std::vector<T> &v) {
|
531
583
|
std::vector<T> ret(v.size());
|
@@ -108,6 +108,11 @@ namespace casadi {
|
|
108
108
|
\identifier{27l} */
|
109
109
|
casadi_int get_constant(const std::vector<char>& v, bool allow_adding=false);
|
110
110
|
|
111
|
+
/** \brief Get or add a vector<string> constant
|
112
|
+
|
113
|
+
\identifier{27z} */
|
114
|
+
casadi_int get_constant(const std::vector<std::string>& v, bool allow_adding=false);
|
115
|
+
|
111
116
|
/** \brief Represent an array constant; adding it when new
|
112
117
|
|
113
118
|
\identifier{rz} */
|
@@ -138,6 +143,11 @@ namespace casadi {
|
|
138
143
|
\identifier{27m} */
|
139
144
|
std::string constant(const std::vector<char>& v);
|
140
145
|
|
146
|
+
/** \brief Represent an array constant; adding it when new
|
147
|
+
|
148
|
+
\identifier{280} */
|
149
|
+
std::string constant(const std::vector<std::string>& v);
|
150
|
+
|
141
151
|
/** \brief Allocate file scope double read-only memory
|
142
152
|
|
143
153
|
\identifier{s2} */
|
@@ -153,6 +163,10 @@ namespace casadi {
|
|
153
163
|
\identifier{s4} */
|
154
164
|
void define_rom_integer(const void* id, casadi_int size);
|
155
165
|
|
166
|
+
/** \brief Setup a callback
|
167
|
+
|
168
|
+
\identifier{27s} */
|
169
|
+
void setup_callback(const std::string& s, const Function& f);
|
156
170
|
/** \brief Access file scope integer read-only memory
|
157
171
|
|
158
172
|
\identifier{s5} */
|
@@ -243,6 +257,7 @@ namespace casadi {
|
|
243
257
|
std::string initializer(const std::vector<double>& v);
|
244
258
|
std::string initializer(const std::vector<casadi_int>& v);
|
245
259
|
std::string initializer(const std::vector<char>& v);
|
260
|
+
std::string initializer(const std::vector<std::string>& v);
|
246
261
|
|
247
262
|
/** \brief Sanitize source files for codegen
|
248
263
|
|
@@ -614,7 +629,12 @@ namespace casadi {
|
|
614
629
|
AUX_MMIN,
|
615
630
|
AUX_MMAX,
|
616
631
|
AUX_LOGSUMEXP,
|
617
|
-
AUX_SPARSITY
|
632
|
+
AUX_SPARSITY,
|
633
|
+
AUX_BFGS,
|
634
|
+
AUX_ORACLE_CALLBACK,
|
635
|
+
AUX_OCP_BLOCK,
|
636
|
+
AUX_ORACLE,
|
637
|
+
AUX_SCALED_COPY
|
618
638
|
};
|
619
639
|
|
620
640
|
/** \brief Add a built-in auxiliary function
|
@@ -657,6 +677,12 @@ namespace casadi {
|
|
657
677
|
void print_vector(std::ostream &s, const std::string& name,
|
658
678
|
const std::vector<double>& v);
|
659
679
|
|
680
|
+
/** \brief Print string vector to a c file
|
681
|
+
|
682
|
+
\identifier{281} */
|
683
|
+
void print_vector(std::ostream &s, const std::string& name,
|
684
|
+
const std::vector<std::string>& v);
|
685
|
+
|
660
686
|
/** \brief Create a copy operation
|
661
687
|
|
662
688
|
\identifier{tt} */
|
@@ -895,6 +921,7 @@ namespace casadi {
|
|
895
921
|
std::multimap<size_t, size_t> added_double_constants_;
|
896
922
|
std::multimap<size_t, size_t> added_integer_constants_;
|
897
923
|
std::multimap<size_t, size_t> added_char_constants_;
|
924
|
+
std::multimap<size_t, size_t> added_string_constants_;
|
898
925
|
std::map<std::string, std::pair<std::string, std::string> > local_variables_;
|
899
926
|
std::map<std::string, std::string> local_default_;
|
900
927
|
std::map<const void *, casadi_int> file_scope_double_;
|
@@ -916,6 +943,7 @@ namespace casadi {
|
|
916
943
|
std::vector<std::vector<double> > double_constants_;
|
917
944
|
std::vector<std::vector<casadi_int> > integer_constants_;
|
918
945
|
std::vector<std::vector<char> > char_constants_;
|
946
|
+
std::vector<std::vector<std::string> > string_constants_;
|
919
947
|
|
920
948
|
// Does any function need thread-local memory?
|
921
949
|
bool needs_mem_;
|
@@ -924,6 +952,7 @@ namespace casadi {
|
|
924
952
|
static size_t hash(const std::vector<double>& v);
|
925
953
|
static size_t hash(const std::vector<casadi_int>& v);
|
926
954
|
static size_t hash(const std::vector<char>& v);
|
955
|
+
static size_t hash(const std::vector<std::string>& v);
|
927
956
|
|
928
957
|
std::string wrapper(const Function& base, const std::string& name);
|
929
958
|
|
@@ -274,6 +274,11 @@ namespace casadi {
|
|
274
274
|
/// Check if evaluation output
|
275
275
|
bool is_output() const;
|
276
276
|
|
277
|
+
/** \brief Check if a multiple output node
|
278
|
+
|
279
|
+
\identifier{284} */
|
280
|
+
bool has_output() const;
|
281
|
+
|
277
282
|
/// Get the index of evaluation output - only valid when is_output() is true
|
278
283
|
casadi_int which_output() const;
|
279
284
|
|
@@ -306,15 +311,23 @@ namespace casadi {
|
|
306
311
|
\identifier{qp} */
|
307
312
|
std::vector<MX> primitives() const;
|
308
313
|
|
314
|
+
/// @{
|
309
315
|
/** \brief Split up an expression along symbolic primitives
|
310
316
|
|
311
317
|
\identifier{qq} */
|
312
318
|
std::vector<MX> split_primitives(const MX& x) const;
|
319
|
+
std::vector<SX> split_primitives(const SX& x) const;
|
320
|
+
std::vector<DM> split_primitives(const DM& x) const;
|
321
|
+
/// @}
|
313
322
|
|
323
|
+
/// @{
|
314
324
|
/** \brief Join an expression along symbolic primitives
|
315
325
|
|
316
326
|
\identifier{qr} */
|
317
327
|
MX join_primitives(const std::vector<MX>& v) const;
|
328
|
+
SX join_primitives(const std::vector<SX>& v) const;
|
329
|
+
DM join_primitives(const std::vector<DM>& v) const;
|
330
|
+
/// @}
|
318
331
|
|
319
332
|
/// \cond INTERNAL
|
320
333
|
/** \brief Detect duplicate symbolic expressions
|
@@ -655,6 +668,7 @@ namespace casadi {
|
|
655
668
|
static MX convexify(const MX& H, const Dict& opts = Dict());
|
656
669
|
static MX stop_diff(const MX& expr, casadi_int order);
|
657
670
|
static MX stop_diff(const MX& expr, const MX& var, casadi_int order);
|
671
|
+
static std::vector<MX> difference(const std::vector<MX>& a, const std::vector<MX>& b);
|
658
672
|
///@}
|
659
673
|
/// \endcond
|
660
674
|
|
@@ -836,13 +850,14 @@ namespace casadi {
|
|
836
850
|
return MX::stop_diff(expr, var, order);
|
837
851
|
}
|
838
852
|
|
853
|
+
/** \bried Return all elements of a that do not occur in b, preserving order */
|
854
|
+
inline friend std::vector<MX> difference(const std::vector<MX>& a, const std::vector<MX>& b) {
|
855
|
+
return MX::difference(a, b);
|
856
|
+
}
|
839
857
|
|
840
858
|
/** @} */
|
841
859
|
#endif // SWIG
|
842
860
|
|
843
|
-
/** \bried Return all elements of a that do not occur in b, preserving order */
|
844
|
-
friend std::vector<MX> difference(const std::vector<MX>& a, const std::vector<MX>& b);
|
845
|
-
|
846
861
|
/** \brief returns itself, but with an assertion attached
|
847
862
|
*
|
848
863
|
* If y does not evaluate to 1, a runtime error is raised
|
@@ -200,6 +200,23 @@ public:
|
|
200
200
|
void set_value(const std::vector<MX>& assignments);
|
201
201
|
/// @}
|
202
202
|
|
203
|
+
/// @{
|
204
|
+
/** \brief Set domain of a decision variable
|
205
|
+
*
|
206
|
+
* \param[in] x decision variable
|
207
|
+
* \param[in] type 'real', 'integer' (default: real)
|
208
|
+
*
|
209
|
+
* \verbatim
|
210
|
+
* opti.set_domain(x, "real")
|
211
|
+
* opti.set_domain(x, "integer")
|
212
|
+
* \endverbatim
|
213
|
+
|
214
|
+
\identifier{27t} */
|
215
|
+
void set_domain(const MX& x, const std::string& domain);
|
216
|
+
|
217
|
+
/// @}
|
218
|
+
|
219
|
+
|
203
220
|
/// Crunch the numbers; solve the problem
|
204
221
|
OptiSol solve();
|
205
222
|
|
@@ -451,6 +468,11 @@ public:
|
|
451
468
|
OPTI_PAR, // parameter
|
452
469
|
OPTI_DUAL_G // dual
|
453
470
|
};
|
471
|
+
enum DomainType {
|
472
|
+
OPTI_DOMAIN_REAL,
|
473
|
+
OPTI_DOMAIN_INTEGER
|
474
|
+
};
|
475
|
+
|
454
476
|
|
455
477
|
struct IndexAbstraction {
|
456
478
|
IndexAbstraction() : start(0), stop(0) {}
|
@@ -475,6 +497,7 @@ public:
|
|
475
497
|
casadi_int n;
|
476
498
|
casadi_int m;
|
477
499
|
VariableType type;
|
500
|
+
DomainType domain;
|
478
501
|
casadi_int count;
|
479
502
|
casadi_int i;
|
480
503
|
casadi_int active_i;
|
@@ -66,12 +66,14 @@ struct casadi_nlpsol_detect_bounds_data {
|
|
66
66
|
T1* lam_xu;
|
67
67
|
};
|
68
68
|
// C-REPLACE "casadi_nlpsol_detect_bounds_data<T1>" "struct casadi_nlpsol_detect_bounds_data"
|
69
|
+
// C-REPLACE "casadi_oracle_data<T1>" "struct casadi_oracle_data"
|
69
70
|
|
70
71
|
// SYMBOL "nlpsol_data"
|
71
72
|
template<typename T1>
|
72
73
|
struct casadi_nlpsol_data {
|
73
74
|
// Problem structure
|
74
75
|
const casadi_nlpsol_prob<T1>* prob;
|
76
|
+
casadi_oracle_data<T1>* oracle;
|
75
77
|
// Variable bounds
|
76
78
|
T1 *lbz, *ubz;
|
77
79
|
// Current primal solution
|
@@ -151,8 +153,6 @@ void casadi_nlpsol_init(casadi_nlpsol_data<T1>* d, const T1*** arg, T1*** res,
|
|
151
153
|
|
152
154
|
}
|
153
155
|
|
154
|
-
// C-REPLACE "fabs" "casadi_fabs"
|
155
|
-
|
156
156
|
// SYMBOL "nlpsol_detect_bounds_before"
|
157
157
|
template<typename T1>
|
158
158
|
int casadi_detect_bounds_before(casadi_nlpsol_data<T1>* d_nlp) {
|
@@ -194,8 +194,14 @@ int casadi_detect_bounds_before(casadi_nlpsol_data<T1>* d_nlp) {
|
|
194
194
|
for (casadi_int i=0;i<p_bounds->ng;++i) {
|
195
195
|
if (p_bounds->is_simple[i]) {
|
196
196
|
// Update lbz/ubz
|
197
|
-
|
198
|
-
T1
|
197
|
+
|
198
|
+
T1 lb = (d_nlp->lbg[i]-d_bounds->b[k])/d_bounds->a[k];
|
199
|
+
T1 ub = (d_nlp->ubg[i]-d_bounds->b[k])/d_bounds->a[k];
|
200
|
+
if (d_bounds->a[k]<0) {
|
201
|
+
T1 tmp = lb;
|
202
|
+
lb = ub;
|
203
|
+
ub = tmp;
|
204
|
+
}
|
199
205
|
casadi_int j = p_bounds->target_x[k];
|
200
206
|
|
201
207
|
if (lb==d_nlp->lbz[j]) {
|
@@ -270,5 +276,14 @@ int casadi_detect_bounds_after(casadi_nlpsol_data<T1>* d_nlp) {
|
|
270
276
|
d_nlp->lam_g[d_bounds->target_u[i]-nx] += (d_nlp->lam[i]>0)*d_nlp->lam[i];
|
271
277
|
}
|
272
278
|
}
|
279
|
+
|
280
|
+
k = 0;
|
281
|
+
for (casadi_int i=0;i<p_bounds->ng;++i) {
|
282
|
+
if (p_bounds->is_simple[i]) {
|
283
|
+
if (d_nlp->lam_g) d_nlp->lam_g[i] /= d_bounds->a[k];
|
284
|
+
k++;
|
285
|
+
}
|
286
|
+
}
|
287
|
+
|
273
288
|
return 0;
|
274
289
|
}
|
@@ -0,0 +1,55 @@
|
|
1
|
+
//
|
2
|
+
// MIT No Attribution
|
3
|
+
//
|
4
|
+
// Copyright (C) 2010-2023 Joel Andersson, Joris Gillis, Moritz Diehl, KU Leuven.
|
5
|
+
//
|
6
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this
|
7
|
+
// software and associated documentation files (the "Software"), to deal in the Software
|
8
|
+
// without restriction, including without limitation the rights to use, copy, modify,
|
9
|
+
// merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
// permit persons to whom the Software is furnished to do so.
|
11
|
+
//
|
12
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
|
13
|
+
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
14
|
+
// PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
15
|
+
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
16
|
+
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
17
|
+
// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
18
|
+
//
|
19
|
+
|
20
|
+
|
21
|
+
// SYMBOL "ocp_block"
|
22
|
+
struct casadi_ocp_block {
|
23
|
+
casadi_int offset_r;
|
24
|
+
casadi_int offset_c;
|
25
|
+
casadi_int rows;
|
26
|
+
casadi_int cols;
|
27
|
+
};
|
28
|
+
// C-REPLACE "casadi_ocp_block" "struct casadi_ocp_block"
|
29
|
+
|
30
|
+
// SYMBOL "unpack_ocp_blocks"
|
31
|
+
template<typename T1>
|
32
|
+
void casadi_unpack_ocp_blocks(casadi_ocp_block* blocks, const casadi_int* packed) {
|
33
|
+
casadi_int i;
|
34
|
+
casadi_int N = *packed++;
|
35
|
+
for (i=0;i<N;++i) {
|
36
|
+
blocks[i].offset_r = *packed++;
|
37
|
+
blocks[i].offset_c = *packed++;
|
38
|
+
blocks[i].rows = *packed++;
|
39
|
+
blocks[i].cols = *packed++;
|
40
|
+
}
|
41
|
+
}
|
42
|
+
|
43
|
+
// SYMBOL "ptr_ocp_block"
|
44
|
+
template<typename T1>
|
45
|
+
void casadi_ptr_ocp_block(casadi_int N, T1** vs, T1* v, const casadi_ocp_block* blocks, int eye) {
|
46
|
+
casadi_int k, offset = 0;
|
47
|
+
for (k=0;k<N;++k) {
|
48
|
+
vs[k] = v+offset;
|
49
|
+
if (eye) {
|
50
|
+
offset += blocks[k].rows;
|
51
|
+
} else {
|
52
|
+
offset += blocks[k].rows*blocks[k].cols;
|
53
|
+
}
|
54
|
+
}
|
55
|
+
}
|
@@ -0,0 +1,44 @@
|
|
1
|
+
//
|
2
|
+
// MIT No Attribution
|
3
|
+
//
|
4
|
+
// Copyright (C) 2010-2023 Joel Andersson, Joris Gillis, Moritz Diehl, KU Leuven.
|
5
|
+
//
|
6
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this
|
7
|
+
// software and associated documentation files (the "Software"), to deal in the Software
|
8
|
+
// without restriction, including without limitation the rights to use, copy, modify,
|
9
|
+
// merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
// permit persons to whom the Software is furnished to do so.
|
11
|
+
//
|
12
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
|
13
|
+
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
14
|
+
// PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
15
|
+
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
16
|
+
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
17
|
+
// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
18
|
+
//
|
19
|
+
|
20
|
+
// C-REPLACE "OracleMemory* m;" ""
|
21
|
+
|
22
|
+
|
23
|
+
// SYMBOL "oracle_data"
|
24
|
+
template<typename T1>
|
25
|
+
struct casadi_oracle_data {
|
26
|
+
const T1** arg;
|
27
|
+
T1** res;
|
28
|
+
casadi_int* iw;
|
29
|
+
T1* w;
|
30
|
+
|
31
|
+
void* m;
|
32
|
+
};
|
33
|
+
|
34
|
+
// C-REPLACE "casadi_oracle_data<T1>" "struct casadi_oracle_data"
|
35
|
+
|
36
|
+
// SYMBOL "oracle_init"
|
37
|
+
template<typename T1>
|
38
|
+
void casadi_oracle_init(casadi_oracle_data<T1>* d, const T1*** arg, T1*** res,
|
39
|
+
casadi_int** iw, T1** w) {
|
40
|
+
d->arg = *arg;
|
41
|
+
d->res = *res;
|
42
|
+
d->iw = *iw;
|
43
|
+
d->w = *w;
|
44
|
+
}
|
@@ -0,0 +1,39 @@
|
|
1
|
+
//
|
2
|
+
// MIT No Attribution
|
3
|
+
//
|
4
|
+
// Copyright (C) 2010-2023 Joel Andersson, Joris Gillis, Moritz Diehl, KU Leuven.
|
5
|
+
//
|
6
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this
|
7
|
+
// software and associated documentation files (the "Software"), to deal in the Software
|
8
|
+
// without restriction, including without limitation the rights to use, copy, modify,
|
9
|
+
// merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
// permit persons to whom the Software is furnished to do so.
|
11
|
+
//
|
12
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
|
13
|
+
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
14
|
+
// PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
15
|
+
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
16
|
+
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
17
|
+
// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
18
|
+
//
|
19
|
+
|
20
|
+
// SYMBOL "oracle_callback"
|
21
|
+
template<typename T1>
|
22
|
+
struct casadi_oracle_callback {
|
23
|
+
int (*eval)(const T1** arg, T1** res, casadi_int* iw, T1* w, int mem);
|
24
|
+
int (*checkout)(void);
|
25
|
+
void (*release)(int);
|
26
|
+
};
|
27
|
+
// C-REPLACE "casadi_oracle_callback<T1>" "struct casadi_oracle_callback"
|
28
|
+
// C-REPLACE "casadi_oracle_data<T1>" "struct casadi_oracle_data"
|
29
|
+
|
30
|
+
// SYMBOL "call"
|
31
|
+
template<typename T1>
|
32
|
+
int casadi_oracle_call(const casadi_oracle_callback<T1>* cb, casadi_oracle_data<T1>* d) {
|
33
|
+
int flag;
|
34
|
+
int mem = 0;
|
35
|
+
if (cb->checkout) mem = cb->checkout();
|
36
|
+
flag = cb->eval(d->arg, d->res, d->iw, d->w, mem);
|
37
|
+
if (cb->release) cb->release(mem);
|
38
|
+
return flag;
|
39
|
+
}
|
@@ -292,6 +292,7 @@ namespace casadi {
|
|
292
292
|
#include "casadi_qrqp.hpp"
|
293
293
|
#include "casadi_kkt.hpp"
|
294
294
|
#include "casadi_ipqp.hpp"
|
295
|
+
#include "casadi_oracle.hpp"
|
295
296
|
#include "casadi_nlp.hpp"
|
296
297
|
#include "casadi_sqpmethod.hpp"
|
297
298
|
#include "casadi_feasiblesqpmethod.hpp"
|
@@ -307,7 +308,9 @@ namespace casadi {
|
|
307
308
|
#include "casadi_sum.hpp"
|
308
309
|
#include "casadi_sparsity.hpp"
|
309
310
|
#include "casadi_jac.hpp"
|
310
|
-
|
311
|
+
#include "casadi_oracle_callback.hpp"
|
312
|
+
#include "casadi_ocp_block.hpp"
|
313
|
+
#include "casadi_scaled_copy.hpp"
|
311
314
|
} // namespace casadi
|
312
315
|
|
313
316
|
/// \endcond
|
@@ -0,0 +1,31 @@
|
|
1
|
+
//
|
2
|
+
// MIT No Attribution
|
3
|
+
//
|
4
|
+
// Copyright (C) 2010-2023 Joel Andersson, Joris Gillis, Moritz Diehl, KU Leuven.
|
5
|
+
//
|
6
|
+
// Permission is hereby granted, free of charge, to any person obtaining a copy of this
|
7
|
+
// software and associated documentation files (the "Software"), to deal in the Software
|
8
|
+
// without restriction, including without limitation the rights to use, copy, modify,
|
9
|
+
// merge, publish, distribute, sublicense, and/or sell copies of the Software, and to
|
10
|
+
// permit persons to whom the Software is furnished to do so.
|
11
|
+
//
|
12
|
+
// THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED,
|
13
|
+
// INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
|
14
|
+
// PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT
|
15
|
+
// HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
|
16
|
+
// OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
|
17
|
+
// SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
18
|
+
//
|
19
|
+
|
20
|
+
// SYMBOL "scaled_copy"
|
21
|
+
template<typename T1>
|
22
|
+
void casadi_scaled_copy(T1 s, const T1* x, casadi_int n, T1* y) {
|
23
|
+
casadi_int i;
|
24
|
+
if (y) {
|
25
|
+
if (x) {
|
26
|
+
for (i=0; i<n; ++i) *y++ = s*(*x++);
|
27
|
+
} else {
|
28
|
+
for (i=0; i<n; ++i) *y++ = 0.;
|
29
|
+
}
|
30
|
+
}
|
31
|
+
}
|
@@ -99,7 +99,7 @@ namespace casadi {
|
|
99
99
|
void unpack(Slice& e);
|
100
100
|
void unpack(int& e);
|
101
101
|
|
102
|
-
#if SIZE_MAX != UINT_MAX
|
102
|
+
#if SIZE_MAX != UINT_MAX || defined(__EMSCRIPTEN__)
|
103
103
|
void unpack(unsigned int& e);
|
104
104
|
#endif
|
105
105
|
void unpack(bool& e);
|
@@ -236,7 +236,7 @@ namespace casadi {
|
|
236
236
|
void pack(const GenericType& e);
|
237
237
|
void pack(std::istream& s);
|
238
238
|
void pack(int e);
|
239
|
-
#if SIZE_MAX != UINT_MAX
|
239
|
+
#if SIZE_MAX != UINT_MAX || defined(__EMSCRIPTEN__)
|
240
240
|
void pack(unsigned int e);
|
241
241
|
#endif
|
242
242
|
void pack(bool e);
|
@@ -1212,6 +1212,13 @@ namespace casadi {
|
|
1212
1212
|
hash_combine(seed, get_ptr(v), v.size());
|
1213
1213
|
}
|
1214
1214
|
|
1215
|
+
template<>
|
1216
|
+
inline size_t hash_value(std::string v) {
|
1217
|
+
size_t seed = 0;
|
1218
|
+
hash_combine(seed, v.c_str(), v.size());
|
1219
|
+
return seed;
|
1220
|
+
}
|
1221
|
+
|
1215
1222
|
/** \brief Hash a sparsity pattern
|
1216
1223
|
|
1217
1224
|
\identifier{ds} */
|