microsoft / microsoft/calculator

Some formulas are tremendously slow to evaluate

Open
#1,850 0 comments 2 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
31.1k
Forks
5.8k
PR merge metrics
No merged PRs in 30d

Description

Describe the bug

There are functions that take forever to compute.
An example is the following:
image
The larger the main factor is (here 3000), the slower the program gets.
1-3 is fine, 30-60 slow, 3000 gets the app stuck, and then it crashed on me.

A side effect on this was, that when trying to capture a screenshot of the formula (with Win+Shift+S), even that program got frozen. Probably Windows was overloaded in this moment. The task manager could be opened just fine though.

Steps To Reproduce

  1. Open calculator
  2. Enable graphing view
  3. Type in my formula, first try small values, then large

Expected behavior

The calculator performance should stay the same, especially because I am only graphing, not doing any analytics of the function.

Screenshots

Device and Application Information

  • OS Build:
Major  Minor  Build  Revision
-----  -----  -----  --------
10     0      19044  0
  • Architecture: X64
  • Application Version: 10.2103.8.0
  • Region: de-DE
  • Dev Version Installed: False

Additional context

Requested Assignment

I'm just reporting this problem. I don't want to fix it.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reproducing the report in Calculator's graphing view on Windows 10, using the formula shown in the attached image and increasing its main factor from small values to 3000. Compare responsiveness and resource use across those values, then verify that graphing remains usable without freezing or crashing.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
desktop, performance
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.