view default_struct.m @ 1184:ecc605453733 feature/rv

Move specialized constructDiffOps* into constructDiffOps.m. Add multigrid RV using the standard RungekuttaRV time stepper
author Vidar Stiernström <vidar.stiernstrom@it.uu.se>
date Fri, 05 Jul 2019 17:51:11 +0200
parents 46256fffa329
children
line wrap: on
line source

function default_struct(s, val)
    if evalin('caller',sprintf('~exist(''%s'',''var'')',s))
        given = [];
    else
        given = evalin('caller', s);
    end

    final = copyWithDefault(given, val);
    assignin('caller', s, final);
end