Okay I think this is because there is another linprog in C:\Program Files\Mosek\8\toolbox\r2014a   idk where this came from or how to get rid of it / deal with it.
linprog example returns empty vector (when it should return 0.6667 1.3333)
    6 ビュー (過去 30 日間)
  
       古いコメントを表示
    
Running this example https://www.mathworks.com/help/optim/ug/linprog.html#buus0qo-2
just gives me   x =[]  what gives I should be getting 
Optimal solution found.
x = 2×1
    0.6667
    1.3333
3 件のコメント
  John D'Errico
      
      
 2020 年 2 月 28 日
				How to get rid of it? Um, you created a file with that name, then saved it on your search path. Don't do that?
It is legal to delete or rename a file that you created. 
In general, it is a bad idea to create files with the same name as MATLAB functions that you will later be using. Else, you will have this exact problem.
回答 (1 件)
  Stephen23
      
      
 2020 年 2 月 29 日
        
      編集済み: Stephen23
      
      
 2020 年 2 月 29 日
  
      "...I think it just got installed when I installed certain matlab packages or something."
It looks like some badly-written third-party toolboxes are shadowing the inbuilt function name/s.
" Also what can I do to prevent overriding these defaults when installing packages?"
You could:
- delete those toolboxes (but usually users want to keep toolboxes), or
- rename those functions (this might not be a trivial task), or
- change the path order so that inbuilt toolboxes have a higher priority (but this could break functionality of those badly-written third-party toolboxes), or
- remove those toolboxes from the Search Path:
For example, you could use restoredefaultpath to reset back to the default Search Path:
0 件のコメント
参考
カテゴリ
				Help Center および File Exchange で Introduction to Installation and Licensing についてさらに検索
			
	Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!


