why I get NaN answer when I use yalmip with mosek solver always even if the problem is very simple ?
14 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
i have download both yalmip and mosek correctly and i have a licence for mosek and i add it to the path before running the code and the answer always the same NaN
i use R2022a matlab version on macbook air m1/ what could be the problem ?
1 comentario
Ive J
el 3 de Jun. de 2023
Editada: Walter Roberson
el 4 de Jun. de 2023
You'll probably have a better chance of finding an answer if try to ask your question here: https://groups.google.com/g/yalmip
Respuestas (1)
Tushar
el 4 de Jun. de 2023
Hi Sara,
If you have correctly installed YALMIP, MOSEK, and added the MOSEK license to the MATLAB path, but you are still getting NaN (Not a Number) as the output of your optimization code, there could be a few possible reasons for this issue. Here are some potential troubleshooting steps:
- Check the Optimization Problem: Make sure that your optimization problem is well-defined and feasible. NaN can occur when the problem is infeasible or unbounded. Double-check your objective function, constraints, and variable bounds to ensure they are correctly specified.
- Verify License and Path: Ensure that your MOSEK license is valid and properly activated. Additionally, confirm that you have correctly added the MOSEK installation directory to the MATLAB path. You can verify this by running the command "which mosekopt" in MATLAB to see if it correctly points to the MOSEK solver.
- Update MOSEK Version: Check if there is a more recent version of MOSEK available and consider updating to the latest version. Sometimes, compatibility issues can arise between specific MATLAB versions and solver versions.
- Debug Your Optimization Code: Examine your optimization code and check for any potential errors or inconsistencies. Make sure you are using the appropriate YALMIP syntax and correctly defining your optimization variables, constraints, and objective function. You can also try running simpler optimization problems to see if they produce valid results.
- Verify Solver Compatibility: Ensure that the version of MOSEK you have installed is compatible with your MATLAB version. Check the MOSEK documentation or contact MOSEK support to confirm compatibility with MATLAB R2022a on the M1 Mac.
- Seek MOSEK Support: If the issue persists, consider reaching out to MOSEK support directly. They can provide specific guidance and troubleshooting steps tailored to your setup and license.
3 comentarios
Walter Roberson
el 13 de Jun. de 2023
The volunteers do not have access to the systems of the people asking questions.
The real problem for the user might be conflicts with drivers for a visual assistive device. Or the real problem for the user might be a bad feedback between two different anti-malware software packages. Or the real problem for the user might be that they are running one of the MacOS versions that mostly disables LD_LIBRARY_PATH . Or the real problem for the user might be the fact that they have installed on an Apple Silicon processor and some portions of the software are running native and some are running under Rosetta 2.
We do not know. We cannot know. Without access to the user's equipment and a bunch of time to test, the best that the volunteers can do is talk about common sources of problems in the kind of configuration the user has.
Ver también
Categorías
Más información sobre Solver Outputs and Iterative Display en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!