Call function foo with all elements in array arguments return an output of same shape as array input elements
quantlib