Is it possible to have a math input graph a student answer like g(x)=f(x)+2 (assuming f(x) is defined)?
Here’s what I’m trying to do in a sample activity.
Is it possible to have a math input graph a student answer like g(x)=f(x)+2 (assuming f(x) is defined)?
Here’s what I’m trying to do in a sample activity.
Function notation is supported in the calculator, but not in the CL. I posted this before, where I sort of fool the calculator into accepting (some) transformations.
I’ve used the concept on this original post to make a variation that is a little more flexible (allows decimal horizontal shifts). The modified activity is Updated transformation
Usually I’m just taking really useful material out of the threads, especially posted by @Daniel_Grubbs…hoping to “give back” just a bit.
You’ll find this solves all your needs i think. It handles any function, any transformation, etc.
Wow! @Mike_Gleeson, that’s really cool, and thanks for sharing it. I seem to get similar results on a good smattering of test cases with the original, but obviously I’m out of luck if I need the extra “multiplier” k that you have “inside” the function. So, the one you shared is definitely more versatile. I’d ask about some of the CL behind the “in” math input, but I’m not sure where to start (guessing there is quite a bit of “parsing” code in there?). Is there any one small part of it you would say would be most useful to look at and learn a bit about for use in other places?
One more side question: is there a list of numbers somewhere I could use to pull in extra colors the way you did on the graph?
Thanks again for sharing, and hopefully not too much trouble with a couple extra questions.
I’m glad you find it useful, hopefully I can help add some clarity to the code.
First though the colours:
is there a list of numbers somewhere I could use to pull in extra colors the way you did on the graph?
Desmos can render colours in two different colour spaces:
You can learn more about the meaning of each parameter here. It would be nice if some other more modern colour spaces were implemented as well but to be fair you can do a lot(particularly with hsv imo).
The code for the function transformations is pretty tricky because desmos isn’t entirely consistent in how it parses things in function notation. Getting used to some of the features of patterns
is the key to much of it. I’m not sure how well documented that really is, though there are some videos about it that will help.
If there’s a specific line though i can explain, please let me know!