view default_field.m @ 770:0090a86d8b72 feature/grids

Improve mononomial and vandermonde functions to work in multiple dimension and adapt to sym or double inputs
author Jonatan Werpers <jonatan@werpers.com>
date Wed, 27 Jun 2018 11:10:52 +0200
parents 14bf01b7a068
children 50cafc4b9e40
line wrap: on
line source

function default_field(s, f, val)
    if isfield(s,f)
        return
    end
    s.(f) = val;
    assignin('caller', inputname(1),s);
end