# Bug? numericValue accepts x

**URL:** <https://cl.desmos.com/t/bug-numericvalue-accepts-x/3579>\
**Category:** Questions\
**Created:** [August 5, 2021, 3:07pm UTC](https://cl.desmos.com/t/bug-numericvalue-accepts-x/3579 "2021-08-05T15:07:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mike\_Gleeson](https://yyz1.discourse-cdn.com/flex031/user_avatar/cl.desmos.com/mike_gleeson/32/650_2.png) [@Mike\_Gleeson](https://cl.desmos.com/u/Mike_Gleeson)\
**Post date:** [August 5, 2021, 3:07pm UTC](https://cl.desmos.com/t/bug-numericvalue-accepts-x/3579/1 "2021-08-05T15:07:27Z")

</div>

Interesting problem I just encountered. According to the documentation:

> **numericValue** gets the evaluated value of an expression input. For example, “2+2” will return the number 4.

However this doesn’t appear to be entirely accurate as numericValue is seemingly unable to distinguish between numbers and expressions directly linear in terms of `x`.

For example something like, say, `3x` versus `3`: they’re the same according to numericValue.

Try it, say, [here](https://teacher.desmos.com/activitybuilder/custom/5eced0e567e76d0f48af71b2/edit-readonly/published#step=c03214c7-b09d-4405-bdc7-363b8942a005&preview).

This is a fairly subtle but serious bug. Any thoughts on this?

---

<div class="post-metadata">

**Author:** ![cwinske](https://yyz1.discourse-cdn.com/flex031/user_avatar/cl.desmos.com/cwinske/32/3106_2.png) [@cwinske](https://cl.desmos.com/u/cwinske)\
**Post date:** [August 5, 2021, 3:43pm UTC](https://cl.desmos.com/t/bug-numericvalue-accepts-x/3579/2 "2021-08-05T15:43:40Z")

</div>

While I’m not disputing anything you are saying, I think Jay described their thinking [in this thread](https://cl.desmos.com/t/why-does-it-accept-letters-after-number-in-math-input/3252). The back end coding must have something like the firstDefinedValue built into numericValue to ignore possible units.

---

<div class="post-metadata">

**Author:** ![Mike\_Gleeson](https://yyz1.discourse-cdn.com/flex031/user_avatar/cl.desmos.com/mike_gleeson/32/650_2.png) [@Mike\_Gleeson](https://cl.desmos.com/u/Mike_Gleeson)\
**Post date:** [August 5, 2021, 3:48pm UTC](https://cl.desmos.com/t/bug-numericvalue-accepts-x/3579/3 "2021-08-05T15:48:34Z")

</div>

Wow, i even replied to that thread. Completely forgot.

It’s a straight out mathematical error and I’m imploring Desmos to fix this as it’s wrong mathematically and wrong from a units point of view as well.

The idea that somehow units need to be accounted for is also [not consistent with SI convention](https://physics.nist.gov/cuu/Units/checklist.html), where spaces are always required between numeric values and units, so that edge case simply does not wash.

Thanks for replying @cwinske!
