from workspace to m.file

조회 수: 6(최근 30일)
Recep
Recep 2011년 3월 31일
Hello. I want to take a variable from workspace to m-file. After I will process this variable and I will send to simulink. Could you help me please?

채택된 답변

Paulo Silva
Paulo Silva 2011년 3월 31일
if your m file is just code (not a function) the variables are in the same scope as the worspace, you just need to call them like you do in the workspace, if you are inside a function you should provide the variable as argument to the function or use fun=evalin('base','funname') inside your function code to get the variable value from the workspace.
  댓글 수: 7
Recep
Recep 2011년 3월 31일
Thank you, I hope I can solve problem and error. If you find more information, please let me know.

댓글을 달려면 로그인하십시오.

추가 답변(1개)

Kaustubha Govind
Kaustubha Govind 2011년 3월 31일
You might find it useful to read the documentation on Running Parallel Simulations. There is also Solution #1-6GRUQ3 that describes the broader usage of Parallel Computing Toolbox with Simulink.
  댓글 수: 1
Recep
Recep 2011년 3월 31일
Thank you, I hope I can solve problem and error. If you find more information, please let me know.

댓글을 달려면 로그인하십시오.

범주

Find more on Manual Performance Optimization in Help Center and File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by