There is no way to do that in MATLAB, at least not without knowing the internal operations of the Symbolic engine.
In MATLAB when you create a symbolic function that is non-scalar, there is no way (short of internal operations) to index the function to get to one particular calculation.
You have several options at this point:
- call the symbolic function passing in symbolic parameters, getting out a symbolic array that you then index; or
- create g as a cell array instead of using []. You would not be able to directly do things such int(g) or directly evaluate g at a parameter, but you would be able to index; or
- use unsupported calls into the symbolic engine and arcane knowledge to do the indexing.