Use objects of class 'ConstantGammaClutter' only as scalars or use a cell array

4 visualizaciones (últimos 30 días)
I am trying to use the ConstantGammaClutter object example MathWorks has posted and run into the above error. Here is the relevant portion of code (copied from MathWorks):
clutter = phased.ConstantGammaClutter('Sensor',array,...
'PropagationSpeed',c,'OperatingFrequency',fc,'PRF',prf,...
'SampleRate',fs,'Gamma',tergamma,'EarthModel','Flat',...
'TransmitERP',tpower,'PlatformHeight',height,...
'PlatformSpeed',speed,'PlatformDirection',direction,...
'BroadsideDepressionAngle',depang,'MaximumRange',Rmax,...
'AzimuthCoverage',Azcov,'SeedSource','Property',...
'Seed',40547);
% Simulate the clutter return for 10 pulses.
Nsamp = fs/prf;
Npulse = 10;
sig = zeros(Nsamp,Nele,Npulse);
for m = 1:Npulse
sig(:,:,m) = clutter();
end
MATLAB seems to object to my referencing clutter with parentheses, in the loop. I assume this is do to my operating MATLAB 2015b, not the current 2016b. I have virtually no experience with cell arrays so I'm not sure how to alter the above code. Help?

Respuesta aceptada

Honglei Chen
Honglei Chen el 3 de En. de 2017
This is not about the cell array since there is only one clutter object. It is really because you are using R2015b so the new syntax of running System object with the name is not supported. To get around this error, replace the line
sig(:,:,m) = clutter();
with
sig(:,:,m) = step(clutter);
it should just run fine. You can find more information about this alternative syntax in the following reference page (the first row in Common Methods table)
HTH

Más respuestas (0)

Categorías

Más información sobre Array Geometries and Analysis 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!

Translated by