0001 function mdl = eidors_model_params( mdl );
0002
0003
0004
0005
0006
0007
0008
0009
0010 warning('EIDORS:deprecated','EIDORS_MODEL_PARAMS is deprecated as of 02-Jul-2012. ');
0011
0012 try
0013 type=mdl.type;
0014 catch
0015 error('eidors_model_params: object is not eidors object (no type)');
0016 end
0017
0018 switch type;
0019 case 'inv_model';
0020 mdl.fwd_model= eidors_model_params( mdl.fwd_model );
0021 if ~isfield(mdl,'reconst_type');
0022 mdl.reconst_type= 'difference';
0023 end
0024
0025 case 'fwd_model';
0026 mdl = mdl_normalize(mdl,mdl_normalize(mdl));
0027
0028
0029
0030 if ~isfield(mdl,'elems');
0031 return;
0032 end
0033
0034 mdl.elems= double(mdl.elems);
0035 if isfield(mdl,'boundary')
0036 mdl.boundary= double(mdl.boundary);
0037 else
0038 mdl.boundary= find_boundary(mdl.elems);
0039 end
0040
0041
0042 mdl.n_elem = size(mdl.elems,1);
0043 mdl.n_node = size(mdl.nodes,1);
0044 if isfield(mdl,'electrode');
0045 mdl.n_elec = length(mdl.electrode);
0046 else
0047 mdl.n_elec = 0;
0048 end
0049 end