Defining vector of integrals with undefined function

조회 수: 1(최근 30일)
Florian Spicher
Florian Spicher 2021년 10월 26일
편집: Florian Spicher 2021년 10월 26일
Hi! What I'd like to do is to define a function r, which takes a function f and a partition xi as arguments. r would be a vector, which elements would be defined by the integral from 0 to 1 of f*bj. Where f is the given function and the bj's are functions defined before in my program. The only thing that really matters for these functions are that they depend on x.
My problem is I don't really know how to do this. Here's my lattest attempt. Thanks for the help!
function int_r=r(f,xi)
for j=1:n


Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by