Dynare_config

Hi ! )
Just very interesred in configuration file)
this is a part of an authentic code

[code]%% Set mex routine names
mex_status = cell(1,3);
mex_status(1,1) = {‘mjdgges’};
mex_status(1,2) = {‘qz’};
mex_status(1,3) = {‘Generalized QZ’};
mex_status(2,1) = {‘gensylv’};
mex_status(2,2) = {‘gensylv’};
mex_status(2,3) = {‘Sylvester equation solution’};
mex_status(3,1) = {‘A_times_B_kronecker_C’};
mex_status(3,2) = {‘kronecker’};
mex_status(3,3) = {‘Kronecker products’};
mex_status(4,1) = {‘sparse_hessian_times_B_kronecker_C’};
mex_status(4,2) = {‘kronecker’};
mex_status(4,3) = {‘Sparse kronecker products’};
mex_status(5,1) = {‘local_state_space_iteration_2’};
mex_status(5,2) = {‘particle/local_state_space_iteration’};
mex_status(5,3) = {‘Local state space iteration (second order)’};
number_of_mex_files = size(mex_status,1);

%% Remove some directories from matlab’s path. This is necessary if the user has
%% added dynare_v4/matlab with the subfolders. Matlab has to ignore these
%% subfolders if valid mex files exist.
matlab_path = path;
for i=1:number_of_mex_files
test = strfind(matlab_path,[dynareroot mex_status{i,2}]);
action = length(test);
if action
rmpath([dynareroot mex_status{i,2}]);
matlab_path = path;
end
end[/code]

Why the cycle is organized only to check highlighted dll files? I mean what if I have other files exist both in dynareroot and as a subfolder in matlab path?
Hope it wouldn’t bore for you to answer)
Thanks in advance!

Sorry, but I don’t understand the question. We check for the presence of our prepackaged mex-files and remove some paths to avoid naming conflicts. Do you face a particular problem?

Thanks for reply!
there is not a problem, everything is working, I’m just interested why this cycle is so specific, why not to check all prepackaged mex-files and remove all paths if exist? I must be wrong, but It seems strange somehow…

One more question if you don’t mind, cause I’ve just started my friendship with dynare)
what does command: (status,result)=system(command) do? (command) - dynareroot with model file name] is it run dynare.exe or…?

It runs the dynare_m.exe, which is the preprocessor that creates the m-files Dynare uses.

preprocessor creates some additional m-files, and how to find them? And what about evalin(‘base’, model_name) command, is it also run in exe file? or it is using those additional files? I mean is it possible to see the code which form the structure of M_ and oo_ and others?

The files are in the folder, e.g. the _dynamic.m and _static.m. The evalin-command runs the m-file with the same name as your mod-file. If your mod-file is called mymodel.mod, the m-file is called mymodel.m.
All Dynare codes that are run are accessible via debugging in Matlab.