How to use structure variables from one matlab file inside a classdef which creates function and use in another matlab file

3 次查看(过去 30 天)
Hi,
I am new to OOP in matlab.
I have lot of data which I classify into different m files. and creating functions inside a classdef which can be used directly in one outfile m file.
I have attached duplicate scripts for reference.
I am unable to run the final m file. Its throwing error as
Unable to resolve the name par.a.
Error in funcs.func1 (line 7)
res = (x*(par.a +par.b +par.c))+con.gravity;
Error in Outfile (line 5)
result = funcs.func1(z);

回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Whos 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by