Skip to main content

When to use the 'Is Unit Expression With Equivalent Quantity'?

E
Written by Eric Bouwers
Updated over 2 weeks ago

Grasple has multiple check methods using the Computer Algebra System (CAS) which can be used within the editor to indicate when the answer of a student should be marked correct/incorrect. A full list of current options can be found in this article.
​
This article covers the Is Unit Expression With Equivalent Quantity check. There are two sections in this article:

  1. When to use the Is Unit Expression With Equivalent Quantity check?

  2. How does the Is Unit Expression With Equivalent Quantity check work?

When to use the Is Unit Expression With Equivalent Quantity check?

This checks allows you to check if a given left-hand side (usually the answer given by a student) describes the same dimension as a given quantity. On the right-hand side you can provide either a:

  • full unit expression such as 2 N

  • only a quantity such as newton

If the exact form of the quantity is important you can use the Is Unit Expression With Exact Quantity check.

How does the Is Unit Expression With Equivalent Quantity check work?

As a first step the check will extract the quantities from both sides. If possible, the check will check if the quantities describe the same dimension. For example, the quantities meter and millimeter both describe the dimension length, which means that they will be considered equal.

It could be that either one (or both) of the quantities do not directly describe a dimension. For example, 'force' can be described by newton, but also by the expressions kg * m * s^{-2} or g * m * s^{-2}.

To determine equality in these cases the check will determine if one quantity is a scaled factor of the other quantity. This is done by first converting the first quantity into the other quantity (using the sympy conversion), and then dividing the result by second quantity. If the resulting value is a number the quantities are considered to be equal to each other.

Questions or Feedback

Do you want to know more about this check, whether you should use it for your exercise or any of the other checks? Please let us know via the chat icon in the right bottom of the screen!

Did this answer your question?