Skip to content

Conversation

mohos26
Copy link

@mohos26 mohos26 commented May 16, 2025

This feature proposes adding two new problem generators to complement the existing velocity_of_object function in misc.py, which calculates velocity using displacement and time. The goal is to expand the set of kinematics problems involving constant velocity by covering the two remaining variable types: displacement and time.

With add the names of the functions in _gen_list.py

Proposed _Additions
displacement_of_object

Solves for displacement given velocity and time.

Example:
Problem: An object moves with a constant velocity of $20 m/s$ for $5$ seconds. What is the displacement of the object?
Solution: $100 m$

time_of_object

Solves for time given displacement and velocity.

Example:
Problem: An object travels a distance of $200 m$ at a constant velocity of $50 m/s$. How much time does it take?
Solution: $4.0 s$

Both generators follow the format and structure of the existing velocity generator for consistency.

@mohos26
Copy link
Author

mohos26 commented Jul 3, 2025

Hi! I noticed that the test failure isn't related to the code itself, but rather a missing download for actions/cache@v1 in the GitHub Actions workflow.

I believe the fix would be to update it to actions/cache@v2 or @V3 in the workflow file.

Let me know if you'd like me to open a separate PR for this update.

Thanks again, and looking forward to your feedback on the generators!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant