% Consider the function f(x) = x^2 + log10(x) + 1
F = [1 2; 3 4]
res = F.^2 + log10(F) + 1 % result

G = [2 2; 1 1]
res = G.^2 + log10(G) + 1

% Or we can use an anonymous function
f = @(x) x.^2 + log10(x) + 1

f(F)
f(G)