require file ext, output a function with argument

1. The simulink model name must include extension.
2. Output file is a function not a script.
3. The output function accepts an input argument that specifies the name
of generated simulink model.