Coulomb's Law | Engineering Calculator API
Posted on March 1, 2026 by Boden Bensema
Coulomb's Law API
Formula
where
Description
This endpoint computes values using Coulomb's Law for the electrostatic force between two charges. The API can solve for any unknown variable given sufficient inputs and supports both single-distance and multi-distance comparisons.
It supports:
- Solving for , , , , or
- Comparing forces at two distances and
- Custom dielectric media using
- Signed forces (repulsive , attractive )
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
F | float | optional | Electrostatic force in newtons |
q1 | float | optional | First charge in coulombs |
q2 | float | optional | Second charge in coulombs |
q_product | float | optional | Product in |
r | float | optional | Separation distance in meters |
r_i | float | optional | Initial distance for comparison |
r_f | float | optional | Final distance for comparison |
epsilon_r | float | optional | Relative permittivity (default = 1.0) |
k | float | optional | Coulomb constant override |
signed | bool | optional | Whether to include force sign |
Behavior
- If both
q1andq2are provided,q_productis computed automatically. - If
q_productand one charge are provided, the other charge is derived. - If both
r_iandr_fare provided, the API returns forces at both distances along with change and ratio. - If solving for a single unknown, all other required values must be provided.
- If all values are provided, the API verifies consistency.
Derived Quantities
When sufficient data is available, the API also computes:
-
Electric potential energy
-
Electric field from each charge
Example Summary Output
-
Solving for force:
-
Solving for distance:
-
Multi-distance comparison:
with change and ratio
Notes
- when solving for
- Sign of force depends on charge polarity when
signed=true
About the Author
This article was written by Boden Bensema, an electronics hobbyist focused on teaching beginner-friendly circuit design, breadboarding, and electronics fundamentals.
About page