I am new to R. any help is welcome. Let's say I have a function A in R that returns a matrix A(x). How i can I compute ? I am aware of the existence of integrate, but this function works only with scalar functions. thank you in advance
I would just do a loop for it with rectangles or something.
res=0
for (i in seq(0,1,1/10000)[-10001])
res=res+A(i)
res=res/10000