free_viscous
Determines the free vibration of a single-degree-of-freedom system with viscous damping
Interface
#include <codecogs/engineering/structures/free_viscous.h>
using namespace Engineering::Structures;
Overview
Consider the diagram below in which you have an object of mass m sliding with no friction due to the action of the spring in the left side of the diagram having spring constant k.

This module computes the displacement u of the object at any given moment of time, relative to the static equilibrium point. The constant c is called the coefficient of viscous damping and the values of and
are calculated using the following rules
where is the critical damping coefficient and may be calculated using the formula:
Since the governing equation of this type of motion is given by
this module basically evaluates the solution to the above second-order linear differential equation with constant coefficients.
We distinguish four types of solutions, based on the value of the viscous damping factor . Also consider the initial conditions
and
.
- the undamped case (
)
- the underdamped case (
)
- the critically damped case (
)
- the overdamped case (
)
References
"Structural Dynamics - An Introduction to Computer Methods", Roy R. Craig, Jr.
Note:
This module can also be used to study vertical free vibration, relative to the appropriate point of static equilibrium determined by the cancellation of the weight of the object and the other forces in the system.
FUNCTION
free_viscous
The example below calculates the displacement of a single-degree-of-freedom system having an undamped natural frequency rad/s and a damping factor
. Also the initial displacement
is considered null, while the initial velocity is
m/s. The solution is evaluated over a period of 10 seconds with steps of half a second.
Example 1
#include <codecogs/engineering/structures/free_viscous.h>
#include <stdio.h>
int main() {
double omega = 5, eta = 0.2,
init_displacement = 0, init_velocity = 20;
for (double t = 0; t < 10.5; t += 0.5)
printf("t = %lf\tu(t) = %lf\n", t,
Engineering::Structures::free_viscous(t, omega, eta,
init_displacement, init_velocity));
return 0;
}Output
t = 0.000000 u(t) = 0.000000
t = 0.500000 u(t) = 1.580175
t = 1.000000 u(t) = -1.475793
t = 1.500000 u(t) = 0.796992
t = 2.000000 u(t) = -0.201432
t = 2.500000 u(t) = -0.105072
t = 3.000000 u(t) = 0.172233
t = 3.500000 u(t) = -0.122202
t = 4.000000 u(t) = 0.050769
t = 4.500000 u(t) = -0.002460
t = 5.000000 u(t) = -0.016380
t = 5.500000 u(t) = 0.016203
t = 6.000000 u(t) = -0.009107
t = 6.500000 u(t) = 0.002544
t = 7.000000 u(t) = 0.000974
t = 7.500000 u(t) = -0.001846
t = 8.000000 u(t) = 0.001365
t = 8.500000 u(t) = -0.000596
t = 9.000000 u(t) = 0.000055
t = 9.500000 u(t) = 0.000168
t = 10.000000 u(t) = -0.000177Parameters
Returns
Interactive Calculator
Computing…
Set a range above first to export a graph.
FUNCTION
free_viscous
The example below calculates the displacement of a single-degree-of-freedom system having an object of mass kg, a spring constant
N/m and a coefficient of viscous damping
Ns/m. Also the initial displacement
is considered null, while the initial velocity is
m/s. The solution is evaluated over a period of 10 seconds with steps of half a second.
Example 1
#include <codecogs/engineering/structures/free_viscous.h>
#include <stdio.h>
int main() {
double m = 0.008, k = 0.2, c = 0.016,
init_displacement = 0, init_velocity = 20;
for (double t = 0; t < 10.5; t += 0.5)
printf("t = %lf\tu(t) = %lf\n", t,
Engineering::Structures::free_viscous(t, m, k, c,
init_displacement, init_velocity));
return 0;
}Output
t = 0.000000 u(t) = 0.000000
t = 0.500000 u(t) = 1.580175
t = 1.000000 u(t) = -1.475793
t = 1.500000 u(t) = 0.796992
t = 2.000000 u(t) = -0.201432
t = 2.500000 u(t) = -0.105072
t = 3.000000 u(t) = 0.172233
t = 3.500000 u(t) = -0.122202
t = 4.000000 u(t) = 0.050769
t = 4.500000 u(t) = -0.002460
t = 5.000000 u(t) = -0.016380
t = 5.500000 u(t) = 0.016203
t = 6.000000 u(t) = -0.009107
t = 6.500000 u(t) = 0.002544
t = 7.000000 u(t) = 0.000974
t = 7.500000 u(t) = -0.001846
t = 8.000000 u(t) = 0.001365
t = 8.500000 u(t) = -0.000596
t = 9.000000 u(t) = 0.000055
t = 9.500000 u(t) = 0.000168
t = 10.000000 u(t) = -0.000177Parameters
Returns
Interactive Calculator
Computing…
Set a range above first to export a graph.