matlab-solve-optimization
Use when writing, solving, or debugging MATLAB optimization code — formulating problems (optimproblem, optimvar, fcn2optimexpr), selecting and configuring solvers (fmincon, linprog, quadprog, intlinprog, lsqnonlin, ga, surrogateopt, optimoptions), or validating results (exitflag, convergence, constraint violations). Covers problem-based and solver-based approaches, solver tuning, and solution verification.
npx skills add matlab/matlab-agentic-toolkit --skill matlab-solve-optimization --agent claude-code
Same command for any agent — swap --agent for codex, cursor, copilot.
Weekly change comes from our own snapshots, not the repository page — it measures attention, not adoption.
# MATLAB Optimization Workflow Guide the full optimization lifecycle: classify the problem, formulate it, select and configure a solver, and validate the results. ## When to Use - User is defining an optimization problem in MATLAB (variables, objectives, constraints) - User asks about `optimproblem`, `optimvar`, `optimconstr`, `optimexpr`, or `fcn2optimexpr` - User is selecting or configuring a solver (`optimoptions`, algorithm choice, tuning) - User is interpreting results, debugging convergence, or checking exitflags - User is deciding between problem-based and solver-based approaches - User is writing optimization code with for-loops over decision variables or constraints ## When NOT to Use - User is asking to solve a problem that doesn't require numerical optimization solvers (e.g., finding the minimum value in an array or table) - User is working with non-optimization MATLAB code (data analysis, plotting, signal processing) - User is using a third-party optimization toolbox (not MathWorks) - User is solving symbolic equations with `solve(eqns, vars)`, ODE systems, or linear system solves (`A\b`) --- ## Stage 1: Classify & Formulate ### 1.1 Classify the Problem Before formulati
- When to Use
- When NOT to Use
- Stage 1: Classify & Formulate
- 1.1 Classify the Problem
- 1.2 Choose Approach
- 1.3 Formulate the Problem
- 1.4 Validate at the Start Point
- Stage 2: Select & Configure Solver
- 2.1 Select the Narrowest Solver
- 2.2 Verify Options — Never Guess
- 2.3 Verify Gradients (if supplied)
- 2.4 Parallelize (if expensive)
- 2.5 Performance (after correctness)
- Stage 3: Validate Results
What does the matlab-solve-optimization skill do?
Use when writing, solving, or debugging MATLAB optimization code — formulating problems (optimproblem, optimvar, fcn2optimexpr), selecting and configuring solvers (fmincon, linprog, quadprog, intlinprog, lsqnonlin, ga, surrogateopt, optimoptions), or validating results (exitflag, convergence, constraint violations). Covers problem-based and solver-based approaches, solver tuning, and solution verification.
How do I install it?
Run `npx skills add matlab/matlab-agentic-toolkit --skill matlab-solve-optimization --agent claude-code` — it drops the skill into your project so the agent can pick it up. Swap the --agent value for codex, cursor or copilot if you use one of those.
Where does this skill come from?
From matlab/matlab-agentic-toolkit, a repository with 868 stars. We read it straight from the repository tree rather than a submitted listing, so what you see here is what is actually published.
Is a popular skill a good skill?
Not necessarily. Stars measure attention, not adoption — a repository can trend for a week and be abandoned. That is why we show the weekly change from our own snapshots next to the total, instead of a single flattering number.
