Create a vectorized version of the inline function fun by replacing all occurrences of *, /, etc., with .*, ./, etc.
*
/
.*
./