A library for solving simple mechanics problems
Project description
My Library
This is a Python library for solving simple mechanics problems. Currently, it includes functions for the following calculations:
-
final_velocity(initial_velocity, acceleration, time)
: This function calculates the final velocity of an object given the initial velocity, acceleration, and time. The inputs and output are in meters per second (m/s). -
displacement(initial_velocity, time, acceleration)
: This function calculates the displacement of an object given the initial velocity, time, and acceleration. The inputs and output are in meters (m). -
force(mass, acceleration)
: This function calculates the force exerted on an object given the mass and acceleration. The mass is in kilograms (kg), the acceleration is in meters per second squared (m/s²), and the output is in newtons (N). -
kinetic_energy(mass, velocity)
: This function calculates the kinetic energy of an object given the mass and velocity. The mass is in kilograms (kg), the velocity is in meters per second (m/s), and the output is in joules (J). -
pendulum_period(length, gravity)
: This function calculates the period of a simple pendulum given the length of the pendulum and the acceleration due to gravity. The length is in meters (m), the gravity is in meters per second squared (m/s²), and the output is in seconds (s).
Usage
Here's an example of how to use the final_velocity
function:
import mechanics
v = mechanics.final_velocity(0, 9.8, 10)
print(v) # Prints: 98.0
Project details
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for mechanics-0.1.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5aef94c207162b1b113c0942b8f4ab510a3e645db9d88f55d9683a7ad2173932 |
|
MD5 | 202879be5e25c7c2b3e999ce24ad5b0c |
|
BLAKE2b-256 | 60a5b5cb86d6797ba49d11650c90d35fc228d573eec2f0a1625da7db9d832f25 |