Ask the student to enter a couple of coordinates in a problem

Hi all,

I’ve taken a couple classes on edx.org where students had to input coordinates of a point, (5,6) for example.

Is this functionnality available by default in openedx ? I’ve searched the docs but couldn’t find anything.

I’ve tried setting the answer to a tuple with a python script in the problem editor but no success either…

Are there any ressources that would indicate how to achieve this ?

Thanks

Open edX supports plugins called XBlocks that adds new types of content. It is possible that the exact thing you’re looking for is provided by a custom plugin. You can see a directory of such XBlocks here

Could you share a sample link for this use case? How is it different from a regular text input?

I’ve seen it most recently in MITx - Machine Learning with Python: from Linear Models to Deep Learning.

It’s in Unit 1 > Homework 1 >3. Decision Boundaries :

edx1

And in the following exercise :
edx2

Text input would fail to validate all correct numerical answers, for example (1/3, 1/3), (0.33, 0.33) and (0.333, 0.333) could all be considered valid answers to a question (as well as many others possibilities).

What I’m thinking about is :

  • either let the author ask for a python tuple or list in a numerical input problem (= (2, 2))
  • or let the author specify a pattern e.g. (x_1, x_2) or [x_1, x_2, x_3] as well as the expected values for x_1, x_2, x_3… Then extract the values of x_1, x_2… from the user input and verify each of them as if it was a numerical input problem