I am assuming that you are trying to perform integration of the function f with respect to another function x.
int(expr,val) computes the indefinite integral of expr with respect to the symbolic scalar variable var. To perform integral with respect to another function, int() doesn’t seem to be a proper fit.
Mathematically it can be interpreted as follows
You may adopt the following methodology to implement the above integral
- Take the derivative of the function x with respect to y using ‘diff’ function
- Multiply the f function with the resultant derivative of x function
- Perform symbolic integration on the product with respect to y
You may use the following code snippet for your reference