mirror of
https://github.com/UpsilonNumworks/Upsilon.git
synced 2026-03-26 01:00:50 +01:00
[apps/shared] Move sumBetweenBounds from controller (SumGraphController)
to the models (Sequence or CartesianFunction) and CartesianFunction::sumBetweenBounds takes into account the function domain
This commit is contained in:
@@ -139,7 +139,7 @@ void SumGraphController::reloadBannerView() {
|
||||
assert(!m_record.isNull());
|
||||
ExpiringPointer<Function> function = myApp->functionStore()->modelForRecord(m_record);
|
||||
Poincare::Context * context = myApp->localContext();
|
||||
Poincare::Expression sum = sumBetweenBounds(function, m_startSum, endSum, context);
|
||||
Poincare::Expression sum = function->sumBetweenBounds(m_startSum, endSum, context);
|
||||
result = PoincareHelpers::ApproximateToScalar<double>(sum, context);
|
||||
functionLayout = createFunctionLayout(function);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user