How to plot the variations for integrating parameter
이전 댓글 표시
Hello all,
I have some equations integrated in Matlab. One such set of equations are,
H2Ox = @(EA) -0.0023*(-8/(48000^8))*(((EA)-183000)^7);
H2Oz = integral(H2Ox, 183000, Inf);
Here there are no issues with integration, but I would like to plot the variations for integrating parameter EA. I don't know if Matlab provides the intervals to understand the change in values.
Is it possible to get the EA values as output ? in order to understand as how EA behaves ?
Kindly someone share the thoughts.
Thank you
댓글 수: 7
Ghazwan
2022년 10월 8일
it looks like you need a for-loop for the values variations you want.
Walter Roberson
2022년 10월 8일
integral() divides the initial interval into 10 segments each with 15 nodes. The locations of all active nodes are passed at the same time to the function H2Ox()
integral() then estimates the error for each active segment. Any segment that has a sufficiently low error has its estimated contribution added to the overall sum and then gets deleted from the list of active intervals. Any remaining intervals are subdivided into two pieces and each is reevaluated. This process continues until all intervals have sufficiently low error or 16384 active intervals are reached (i would need to recheck the termination conditions)
Thus during any one call to H2Ox() the function is being asked to evaluate for a number of nodes of intervals that might not be adjacent to each other.
Do I understand correctly that you want to extract a record of the locations evaluated at in order to see how they evolve? To examine, for example, where in the interval are "difficult" to integrate?
Kumaresh Kumaresh
2022년 10월 8일
편집: Kumaresh Kumaresh
2022년 10월 8일
Torsten
2022년 10월 8일
Is it possible to get the EA values as output ? in order to understand as how EA behaves ?
I don't understand your question. EA is the independent variable. It behaves as you prescribe it to behave.
Kumaresh Kumaresh
2022년 10월 10일
Ghazwan
2022년 10월 10일
ok. If you plot it a simple 2D plot, what would be the X and Y axes?
Kumaresh Kumaresh
2022년 10월 10일
채택된 답변
추가 답변 (0개)
카테고리
도움말 센터 및 File Exchange에서 Numerical Integration and Differentiation에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
