This is a static copy of a profile report

Home

Function details for ff_iwkz_vf_vecThis is a static copy of a profile report

Home

ff_iwkz_vf_vec (Calls: 1, Time: 1.922 s)
Generated 03-Jul-2019 19:55:46 using performance time.
function in file C:\Users\fan\CodeDynaAsset\m_akz\solve\ff_iwkz_vf_vec.m
Copy to new window for comparing multiple runs

Parents (calling functions)
No parent
Lines where the most time was spent

Line NumberCodeCallsTotal Time% TimeTime Plot
254
mt_utility = f_grid_interpolan...
16650.532 s27.7%
251
mt_c = f_cons(ar_coh_z', ar_w_...
16650.478 s24.9%
261
mt_utility(mt_c <= fl_c_min...
16650.334 s17.4%
230
ff_wkz_evf(mt_val_wkb_interpol...
1110.112 s5.8%
280
ar_pol_diff_norm(it_iter) = no...
1110.093 s4.8%
All other lines  0.373 s19.4%
Totals  1.922 s100% 
Children (called functions)

Function NameFunction TypeCallsTotal Time% TimeTime Plot
...coh,bprime,kprime)(coh-kprime-bprime)anonymous function16650.374 s19.5%
ff_wkz_evffunction1110.108 s5.6%
meanfunction1110.010 s0.5%
Self time (built-ins, overhead, etc.)  1.430 s74.4%
Totals  1.922 s100% 
Code Analyzer results
Line numberMessage
120The value assigned here to 'ar_w' appears to be unused. Consider replacing it by ~.
135The value assigned here to 'fl_r_save' appears to be unused. Consider replacing it by ~.
135The value assigned here to 'fl_r_borr' appears to be unused. Consider replacing it by ~.
135The value assigned here to 'fl_wage' appears to be unused. Consider replacing it by ~.
Coverage results
Show coverage for parent directory
Total lines in function362
Non-code lines (comments, blank lines)201
Code lines (lines that can run)161
Code lines that did run52
Code lines that did not run109
Coverage (did run/can run)32.30 %
Function listing
time 
Calls 
 line
   7 
function result_map = ff_iwkz_vf_vec(varargin)
   8 
%% FF_IWKZ_VF_VEC solve infinite horizon exo shock + endo asset problem
   9 
% This program solves the infinite horizon dynamic savings and risky
  10 
% capital asset problem with some ar1 shock. This is the vectorized version
  11 
% of
  12 
% <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_iwkz_vf.html
  13 
% ff_iwkz_vf>. See that file for more descriptions. 
  14 
%
  15 
% @param param_map container parameter container
  16 
%
  17 
% @param support_map container support container
  18 
%
  19 
% @param armt_map container container with states, choices and shocks
  20 
% grids that are inputs for grid based solution algorithm
  21 
%
  22 
% @param func_map container container with function handles for
  23 
% consumption cash-on-hand etc.
  24 
%
  25 
% @return result_map container contains policy function matrix, value
  26 
% function matrix, iteration results, and policy function, value function
  27 
% and iteration results tables. 
  28 
%
  29 
% keys included in result_map:
  30 
%
  31 
% * mt_val matrix states_n by shock_n matrix of converged value function grid
  32 
% * mt_pol_a matrix states_n by shock_n matrix of converged policy function grid
  33 
% * ar_val_diff_norm array if bl_post = true it_iter_last by 1 val function
  34 
% difference between iteration
  35 
% * ar_pol_diff_norm array if bl_post = true it_iter_last by 1 policy
  36 
% function difference between iterations
  37 
% * mt_pol_perc_change matrix if bl_post = true it_iter_last by shock_n the
  38 
% proportion of grid points at which policy function changed between
  39 
% current and last iteration for each element of shock
  40 
%
  41 
% @example
  42 
%
  43 
% @include
  44 
%
  45 
% * <https://fanwangecon.github.io/CodeDynaAsset/m_akz/paramfunc/ff_wkz_evf.m ff_wkz_evf>
  46 
% * <https://fanwangecon.github.io/CodeDynaAsset/m_akz/paramfunc/ffs_akz_set_default_param.m ffs_akz_set_default_param>
  47 
% * <https://fanwangecon.github.io/CodeDynaAsset/m_akz/paramfunc/ffs_akz_get_funcgrid.m ffs_akz_get_funcgrid>
  48 
% * <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solvepost/ff_akz_vf_post.m ff_akz_vf_post>
  49 
%
  50 
% @seealso
  51 
%
  52 
% * concurrent (safe + risky) loop: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_akz_vf.html ff_akz_vf>
  53 
% * concurrent (safe + risky) vectorized: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_akz_vf_vec.html ff_akz_vf_vec>
  54 
% * concurrent (safe + risky) optimized-vectorized: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_akz_vf_vecsv.html ff_akz_vf_vecsv>
  55 
% * two-stage (safe + risky) loop: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_wkz_vf.html ff_wkz_vf>
  56 
% * two-stage (safe + risky) vectorized: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_wkz_vf_vec.html ff_wkz_vf_vec>
  57 
% * two-stage (safe + risky) optimized-vectorized: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_wkz_vf_vecsv.html ff_wkz_vf_vecsv>
  58 
% * two-stage + interpolate (safe + risky) loop: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_iwkz_vf.html ff_iwkz_vf>
  59 
% * two-stage + interpolate (safe + risky) vectorized: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_iwkz_vf_vec.html ff_iwkz_vf_vec>
  60 
% * two-stage + interpolate (safe + risky) optimized-vectorized: <https://fanwangecon.github.io/CodeDynaAsset/m_akz/solve/html/ff_iwkz_vf_vecsv.html ff_iwkz_vf_vecsv>
  61 
%
  62 

  63 

  64 
%% Default
  65 
% * it_param_set = 1: quick test
  66 
% * it_param_set = 2: benchmark run
  67 
% * it_param_set = 3: benchmark profile
  68 
% * it_param_set = 4: press publish button
  69 

  70 
it_param_set = 3;
  71 
bl_input_override = true;
  72 
[param_map, support_map] = ffs_akz_set_default_param(it_param_set);
  73 

  74 
% Note: param_map and support_map can be adjusted here or outside to override defaults
  75 
% param_map('it_w_n') = 50;
  76 
% param_map('it_ak_n') = param_map('it_w_n');
  77 
% param_map('it_z_n') = 15;
  78 
% param_map('fl_coh_interp_grid_gap') = 0.1;
  79 
% param_map('it_c_interp_grid_gap') = 10^-4;
  80 

  81 
% parameters can be set inside ffs_akz_set_default_param or updated here
  82 
param_map('it_w_n') = 50;
  83 
param_map('it_ak_n') = param_map('it_w_n');
  84 
param_map('it_z_n') = 15;
  85 
param_map('fl_coh_interp_grid_gap') = 0.1;
  86 
param_map('it_c_interp_grid_gap') = 10^-4;
  87 

  88 
% get armt and func map
  89 
[armt_map, func_map] = ffs_akz_get_funcgrid(param_map, support_map, bl_input_override); % 1 for override
  90 
default_params = {param_map support_map armt_map func_map};
  91 

  92 
%% Parse Parameters 1
  93 

  94 
% if varargin only has param_map and support_map,
  95 
params_len = length(varargin);
  96 
[default_params{1:params_len}] = varargin{:};
  97 
param_map = [param_map; default_params{1}];
  98 
support_map = [support_map; default_params{2}];
  99 
if params_len >= 1 && params_len <= 2
 100 
    % If override param_map, re-generate armt and func if they are not
 101 
    % provided
 102 
    bl_input_override = true;
 103 
    [armt_map, func_map] = ffs_akz_get_funcgrid(param_map, support_map, bl_input_override);
 104 
else
 105 
    % Override all
 106 
    armt_map = [armt_map; default_params{3}];
 107 
    func_map = [func_map; default_params{4}];
 108 
end
 109 

 110 
% append function name
 111 
st_func_name = 'ff_iwkz_vf_vec';
 112 
support_map('st_profile_name_main') = [st_func_name support_map('st_profile_name_main')];
 113 
support_map('st_mat_name_main') = [st_func_name support_map('st_mat_name_main')];
 114 
support_map('st_img_name_main') = [st_func_name support_map('st_img_name_main')];
 115 

 116 
%% Parse Parameters 2
 117 

 118 
% armt_map
 119 
params_group = values(armt_map, {'ar_w', 'ar_z'});
 120 
[ar_w, ar_z] = params_group{:};
 121 
params_group = values(armt_map, {'ar_interp_c_grid', 'ar_interp_coh_grid', ...
 122 
    'mt_interp_coh_grid_mesh_z', 'mt_z_mesh_coh_interp_grid'});
 123 
[ar_interp_c_grid, ar_interp_coh_grid, ...
 124 
    mt_interp_coh_grid_mesh_z, mt_z_mesh_coh_interp_grid] = params_group{:};
 125 
params_group = values(armt_map, {'mt_coh_wkb', 'mt_z_mesh_coh_wkb'});
 126 
[mt_coh_wkb, mt_z_mesh_coh_wkb] = params_group{:};
 127 

 128 
% func_map
 129 
params_group = values(func_map, {'f_util_log', 'f_util_crra', 'f_cons'});
 130 
[f_util_log, f_util_crra, f_cons] = params_group{:};
 131 

 132 
% param_map
 133 
params_group = values(param_map, {'fl_r_save', 'fl_r_borr', 'fl_w',...
 134 
    'it_z_n', 'fl_crra', 'fl_beta', 'fl_c_min'});
 135 
[fl_r_save, fl_r_borr, fl_wage, it_z_n, fl_crra, fl_beta, fl_c_min] = params_group{:};
 136 
params_group = values(param_map, {'it_maxiter_val', 'fl_tol_val', 'fl_tol_pol', 'it_tol_pol_nochange'});
 137 
[it_maxiter_val, fl_tol_val, fl_tol_pol, it_tol_pol_nochange] = params_group{:};
 138 

 139 
% support_map
 140 
params_group = values(support_map, {'bl_profile', 'st_profile_path', ...
 141 
    'st_profile_prefix', 'st_profile_name_main', 'st_profile_suffix',...
 142 
    'bl_time', 'bl_display', 'it_display_every', 'bl_post'});
 143 
[bl_profile, st_profile_path, ...
 144 
    st_profile_prefix, st_profile_name_main, st_profile_suffix, ...
 145 
    bl_time, bl_display, it_display_every, bl_post] = params_group{:};
 146 

 147 
%% Initialize Output Matrixes
 148 

 149 
mt_val_cur = zeros(length(ar_interp_coh_grid),length(ar_z));
 150 
mt_val = mt_val_cur - 1;
 151 
mt_pol_a = zeros(length(ar_interp_coh_grid),length(ar_z));
 152 
mt_pol_a_cur = mt_pol_a - 1;
 153 
mt_pol_k = zeros(length(ar_interp_coh_grid),length(ar_z));
 154 
mt_pol_k_cur = mt_pol_k - 1;
 155 
mt_pol_idx = zeros(length(ar_interp_coh_grid),length(ar_z));
 156 

 157 
%% Initialize Convergence Conditions
 158 

 159 
bl_vfi_continue = true;
 160 
it_iter = 0;
 161 
ar_val_diff_norm = zeros([it_maxiter_val, 1]);
 162 
ar_pol_diff_norm = zeros([it_maxiter_val, 1]);
 163 
mt_pol_perc_change = zeros([it_maxiter_val, it_z_n]);
 164 

 165 
%% Pre-calculate u(c)
 166 
% Interpolation, see
 167 
% <https://fanwangecon.github.io/M4Econ/support/speed/partupdate/fs_u_c_partrepeat_main.html
 168 
% fs_u_c_partrepeat_main> for why interpolate over u(c)
 169 

 170 
% Evaluate
 171 
if (fl_crra == 1)
 172 
    ar_interp_u_of_c_grid = f_util_log(ar_interp_c_grid);
 173 
    fl_u_neg_c = f_util_log(fl_c_min);
 174 
else
 175 
    ar_interp_u_of_c_grid = f_util_crra(ar_interp_c_grid);
 176 
    fl_u_neg_c = f_util_crra(fl_c_min);
 177 
end
 178 
ar_interp_u_of_c_grid(ar_interp_c_grid <= fl_c_min) = fl_u_neg_c;
 179 

 180 
% Get Interpolant
 181 
f_grid_interpolant_spln = griddedInterpolant(ar_interp_c_grid, ar_interp_u_of_c_grid, 'spline');
 182 

 183 
%% Iterate Value Function
 184 
% Loop solution with 4 nested loops
 185 
%
 186 
% # loop 1: over exogenous states
 187 
% # loop 2: over endogenous states
 188 
% # loop 3: over choices
 189 
% # loop 4: add future utility, integration--loop over future shocks
 190 
%
 191 

 192 
% Start Profile
 193 
if (bl_profile)
 194 
    close all;
 195 
    profile off;
 196 
    profile on;
< 0.001 
      1 
 197
end 
 198 

 199 
% Start Timer
< 0.001 
      1 
 200
if (bl_time) 
< 0.001 
      1 
 201
    tic; 
< 0.001 
      1 
 202
end 
 203 

 204 
% Value Function Iteration
< 0.001 
      1 
 205
while bl_vfi_continue 
< 0.001 
    111 
 206
    it_iter = it_iter + 1; 
 207 
    
 208 
    %% Interpolate (1) reacahble v(coh(k(w,z),b(w,z),z),z) given v(coh, z)
 209 
    % v(coh,z) solved on ar_interp_coh_grid, ar_z grids, see
 210 
    % ffs_iwkz_get_funcgrid.m. Generate interpolant based on that, Then
 211 
    % interpolate for the coh reachable levels given the k(w,z) percentage
 212 
    % choice grids in the second stage of the problem
 213 

 214 
    % Generate Interpolant for v(coh,z)
  0.049 
    111 
 215
    f_grid_interpolant_value = griddedInterpolant(... 
    111 
 216
        mt_z_mesh_coh_interp_grid', mt_interp_coh_grid_mesh_z', mt_val_cur', 'linear'); 
 217 
    
 218 
    % Interpoalte for v(coh(k(w,z),b(w,z),z),z)
  0.051 
    111 
 219
    mt_val_wkb_interpolated = f_grid_interpolant_value(mt_z_mesh_coh_wkb, mt_coh_wkb); 
 220 
    
 221 
    %% Solve Second Stage Problem k*(w,z)
 222 
    % This is the key difference between this function and
 223 
    % <https://fanwangecon.github.io/CodeDynaAsset/m_akz/paramfunc/html/ffs_akz_set_functions.html
 224 
    % ffs_akz_set_functions> which solves the two stages jointly    
 225 
    % Interpolation first, because solution coh grid is not the same as all
 226 
    % points reachable by k and b choices given w. 
 227 
    
< 0.001 
    111 
 228
    bl_input_override = true; 
  0.112 
    111 
 229
    [mt_ev_condi_z_max, ~, mt_ev_condi_z_max_kp, mt_ev_condi_z_max_bp] = ... 
    111 
 230
        ff_wkz_evf(mt_val_wkb_interpolated, param_map, support_map, armt_map, bl_input_override); 
 231 
    
 232 
    %% Solve First Stage Problem w*(z) given k*(w,z)
 233 
       
 234 
    % loop 1: over exogenous states
< 0.001 
    111 
 235
    for it_z_i = 1:length(ar_z) 
 236 

 237 
        % State Array fixed        
  0.003 
   1665 
 238
        ar_coh_z = mt_interp_coh_grid_mesh_z(:,it_z_i); 
 239 

 240 
        % Get 2nd Stage Arrays
  0.001 
   1665 
 241
        ar_ev_condi_z_max_z = mt_ev_condi_z_max(:, it_z_i);         
  0.001 
   1665 
 242
        ar_w_kstar_z = mt_ev_condi_z_max_kp(:, it_z_i); 
  0.001 
   1665 
 243
        ar_w_astar_z = mt_ev_condi_z_max_bp(:, it_z_i); 
 244 

 245 
        % Consumption
 246 
        % Note that compared to
 247 
        % <https://fanwangecon.github.io/CodeDynaAsset/m_akz/paramfunc/html/ffs_akz_set_functions.html
 248 
        % ffs_akz_set_functions> the mt_c here is much smaller the same
 249 
        % number of columns (states) as in the ffs_akz_set_functions file,
 250 
        % but the number of rows equal to ar_w length.
  0.478 
   1665 
 251
        mt_c = f_cons(ar_coh_z', ar_w_astar_z, ar_w_kstar_z); 
 252 
        
 253 
        % % Interpolate (2) EVAL current utility: N by N, f_util defined earlier
  0.532 
   1665 
 254
        mt_utility = f_grid_interpolant_spln(mt_c); 
 255 
                
 256 
        % EVAL add on future utility, N by N + N by 1
 257 
        % do not need: mt_evzp_condi_z = mt_val_cur * ar_z_trans_condi'
 258 
        % step because evf_okz_vec solved already. 
 259 
        
  0.049 
   1665 
 260
        mt_utility = mt_utility + fl_beta*ar_ev_condi_z_max_z; 
  0.334 
   1665 
 261
        mt_utility(mt_c <= fl_c_min) = fl_u_neg_c; 
 262 

 263 
        % Optimization: remember matlab is column major, rows must be
 264 
        % choices, columns must be states
 265 
        % <https://en.wikipedia.org/wiki/Row-_and_column-major_order COLUMN-MAJOR>
  0.073 
   1665 
 266
        [ar_opti_val1_z, ar_opti_idx_z] = max(mt_utility); 
  0.010 
   1665 
 267
        mt_val(:,it_z_i) = ar_opti_val1_z; 
  0.016 
   1665 
 268
        mt_pol_a(:,it_z_i) = ar_w_astar_z(ar_opti_idx_z); 
  0.012 
   1665 
 269
        mt_pol_k(:,it_z_i) = ar_w_kstar_z(ar_opti_idx_z);         
< 0.001 
   1665 
 270
        if (it_iter == (it_maxiter_val + 1)) 
< 0.001 
     15 
 271
            mt_pol_idx(:,it_z_i) = ar_opti_idx_z; 
< 0.001 
     15 
 272
        end 
 273 

  0.002 
   1665 
 274
    end 
 275 
    
 276 
    %% Check Tolerance and Continuation
 277 
    
 278 
    % Difference across iterations
  0.051 
    111 
 279
    ar_val_diff_norm(it_iter) = norm(mt_val - mt_val_cur); 
  0.093 
    111 
 280
    ar_pol_diff_norm(it_iter) = norm(mt_pol_a - mt_pol_a_cur) + norm(mt_pol_k - mt_pol_k_cur); 
  0.006 
    111 
 281
    ar_pol_a_perc_change = sum((mt_pol_a ~= mt_pol_a_cur))/(length(ar_interp_coh_grid)); 
  0.004 
    111 
 282
    ar_pol_k_perc_change = sum((mt_pol_k ~= mt_pol_k_cur))/(length(ar_interp_coh_grid));     
  0.013 
    111 
 283
    mt_pol_perc_change(it_iter, :) = mean([ar_pol_a_perc_change;ar_pol_k_perc_change]); 
 284 
    
 285 
    % Update
  0.007 
    111 
 286
    mt_val_cur = mt_val; 
  0.005 
    111 
 287
    mt_pol_a_cur = mt_pol_a; 
  0.005 
    111 
 288
    mt_pol_k_cur = mt_pol_k; 
 289 
    
 290 
    % Print Iteration Results
< 0.001 
    111 
 291
    if (bl_display && (rem(it_iter, it_display_every)==0)) 
 292 
        fprintf('VAL it_iter:%d, fl_diff:%d, fl_diff_pol:%d\n', ...
 293 
            it_iter, ar_val_diff_norm(it_iter), ar_pol_diff_norm(it_iter));
 294 
        tb_valpol_iter = array2table([mean(mt_val_cur,1);...
 295 
                                      mean(mt_pol_a_cur,1); ...
 296 
                                      mean(mt_pol_k_cur,1); ...
 297 
                                      mt_val_cur(length(ar_interp_coh_grid),:); ...
 298 
                                      mt_pol_a_cur(length(ar_interp_coh_grid),:); ...
 299 
                                      mt_pol_k_cur(length(ar_interp_coh_grid),:)]);
 300 
        tb_valpol_iter.Properties.VariableNames = strcat('z', string((1:size(mt_val_cur,2))));
 301 
        tb_valpol_iter.Properties.RowNames = {'mval', 'map', 'mak', 'Hval', 'Hap', 'Hak'};
 302 
        disp('mval = mean(mt_val_cur,1), average value over a')
 303 
        disp('map  = mean(mt_pol_a_cur,1), average choice over a')
 304 
        disp('mkp  = mean(mt_pol_k_cur,1), average choice over k')
 305 
        disp('Hval = mt_val_cur(it_ameshk_n,:), highest a state val')
 306 
        disp('Hap = mt_pol_a_cur(it_ameshk_n,:), highest a state choice')
 307 
        disp('mak = mt_pol_k_cur(it_ameshk_n,:), highest k state choice')                
 308 
        disp(tb_valpol_iter);
 309 
    end
 310 
    
 311 
    % Continuation Conditions:
 312 
    % 1. if value function convergence criteria reached
 313 
    % 2. if policy function variation over iterations is less than
 314 
    % threshold
< 0.001 
    111 
 315
    if (it_iter == (it_maxiter_val + 1)) 
< 0.001 
      1 
 316
        bl_vfi_continue = false; 
  0.001 
    110 
 317
    elseif ((it_iter == it_maxiter_val) || ... 
    110 
 318
            (ar_val_diff_norm(it_iter) < fl_tol_val) || ... 
    110 
 319
            (sum(ar_pol_diff_norm(max(1, it_iter-it_tol_pol_nochange):it_iter)) < fl_tol_pol)) 
 320 
        % Fix to max, run again to save results if needed
< 0.001 
      1 
 321
        it_iter_last = it_iter; 
< 0.001 
      1 
 322
        it_iter = it_maxiter_val;         
< 0.001 
      1 
 323
    end 
 324 
    
< 0.001 
    111 
 325
end 
 326 

 327 
% End Timer
< 0.001 
      1 
 328
if (bl_time) 
< 0.001 
      1 
 329
    toc; 
< 0.001 
      1 
 330
end 
 331 

 332 
% End Profile
< 0.001 
      1 
 333
if (bl_profile) 
  0.006 
      1 
 334
    profile off 
 335 
    profile viewer
 336 
    st_file_name = [st_profile_prefix st_profile_name_main st_profile_suffix];
 337 
    profsave(profile('info'), strcat(st_profile_path, st_file_name));
 338 
end
 339 

 340 
%% Process Optimal Choices
 341 

 342 
result_map = containers.Map('KeyType','char', 'ValueType','any');
 343 
result_map('mt_val') = mt_val;
 344 
result_map('mt_pol_idx') = mt_pol_idx;
 345 

 346 
result_map('cl_mt_pol_coh') = {mt_interp_coh_grid_mesh_z, zeros(1)};
 347 
result_map('cl_mt_pol_a') = {mt_pol_a, zeros(1)};
 348 
result_map('cl_mt_pol_k') = {mt_pol_k, zeros(1)};
 349 
result_map('cl_mt_pol_c') = {f_cons(mt_interp_coh_grid_mesh_z, mt_pol_a, mt_pol_k), zeros(1)};
 350 
result_map('ar_st_pol_names') = ["cl_mt_pol_coh", "cl_mt_pol_a", "cl_mt_pol_k", "cl_mt_pol_c"];
 351 

 352 
if (bl_post)
 353 
    bl_input_override = true;
 354 
    result_map('ar_val_diff_norm') = ar_val_diff_norm(1:it_iter_last);
 355 
    result_map('ar_pol_diff_norm') = ar_pol_diff_norm(1:it_iter_last);
 356 
    result_map('mt_pol_perc_change') = mt_pol_perc_change(1:it_iter_last, :);
 357 
    
 358 
    % graphing based on coh_wkb, but that does not match optimal choice
 359 
    % matrixes for graphs. 
 360 
    armt_map('mt_coh_wkb') = mt_interp_coh_grid_mesh_z;
 361 
    armt_map('it_ameshk_n') = length(ar_interp_coh_grid);
 362 
    armt_map('ar_a_meshk') = mt_interp_coh_grid_mesh_z(:,1);
 363 
    armt_map('ar_k_mesha') = zeros(size(mt_interp_coh_grid_mesh_z(:,1)) + 0);
 364 
    
 365 
    result_map = ff_akz_vf_post(param_map, support_map, armt_map, func_map, result_map, bl_input_override);
 366 
end
 367 

 368 
end

Other subfunctions in this file are not included in this listing.