Welcome to Vibrationdata Matlab Page

 Dear Guest,
Writing tutorials and maintaining a website are expensive endeavors. I need your help to continue this effort. Your donation is appreciated.
Support Vibrationdata

Thank you for your support.
Sincerely, Tom Irvine
Email: tom@irvinemail.org
Tutorials
Power Spectral Density Calculation via Matlab: psd_mat.pdf
Guest tutorial submitted by Bob Light.

Classic Pulse Base Input Shock Analysis
Matlab Scripts
Response of a Single-degree-of-freedom System Subjected to a Half-sine Base Excitation

halfsine.m
time_calc.m
SDOF_base_animation_function.m

sbase.pdf

Response of a Single-degree-of-freedom System Subjected to a Versed-sine Base Excitation
versed_sine.m
versed_time_calc.m

sbase_versed_sine.pdf

SDOF response to a terminal sawtooth base input.
terminal_sawtooth.m
terminal_sawtooth_time_calc.m

terminal_sawtooth.pdf

SDOF response to a wavelet base input.
sdof wavelet.m

sbase_wavelet.pdf

SDOF response to combined sinusoidal force and base excitation.

sdof_force_accel.m

sdof_force_accel.pdf

SDOF response to unit step force

unit_step_force.m

force_unit_step.pdf

TWO-DOF response to applied force excitation.

two_dof_force_sine.m

gencoord.pdf
TWO-DOF response to a wavelet base input.
twodof wavelet.m
twodof_wavelet.pdf
 Additional Shock Analysis Matlab Scripts
SRS Matlab Script (Kelly-Richman & Smallwood) srs.m

Supporting functions:
srs_coefficients.m
enter_time_history.m

find_max.m
fix_size.m

srs_intr.pdf

DS_SRS1.pdf
SRS via convolution srs_conv.m
Time history response of a single-degree-of-freedom system to an arbitrary acceleration base input via a digitial recursive filtering relationship. arbit.m

Supporting function:
srs_coefficients_avd.m
plot_peak_histogram.m
plot_TH.m
plot_histogram.m
enter_time_history.m
Tripartite Shock Response Spectra Plot srs_tripartite.zip
This script demonstrates how an SRS can be calculated from a time history using an FFT as an intermediate step.
srs_from_fft.m

Supporting functions:

sdof_base_accel_transfer.m

enter_time_history.m

full_FFT_core.m
fix_size.m
Mean filter method for removing saturation with optimization. mean_filter_saturation.m

Supporting functions
enter_time_history.m
mr_SRS.m
SRS plotting function SRS_plot.m
Interpolate an SRS function. interp_SRS.m
Shock pulse effective duration per MIL-STD-810F shock_effective_duration.m

progressbar.m
Waveform reconstruction via wavelets. waveform_reconstruct.m

wgen.m

wavelet_reconstruction.pdf
Scale a wavelet table to match an SRS specification. wavelet_scale_SRS.m

wqsrs.m

werror.m
Time history from a wavelet table. th_from_wavelet_table.m
SRS amplitude conversion utility srs_rel_disp.m

Fouier Transforms
Matlab Scripts
Fourier transform
fourier.m 
Supporting functions:
find_max.m
fix_size.m
plot_TH.m
plot_PSD.m
mean_removal_Hanning.m

enter_time_history.m

progressbar.m
Inverse Fourier transform
invfourier.m
One-sided, Full-amplitude FFT
full_FFT.m
Supporting function:
full_FFT_core.m
fix_size.m
find_max.m
 enter_time_history.m

 fft.pdf 
Waterfall FFT
waterfall_FFT.m
Supporting function:
waterfall_FFT_time_process.m
waterfall_FFT_advise.m
waterfall_FFT_time_freq_set.m
waterfall_FFT_core.m
waterfall_FFT_plots.m
fix_size.m

enter_time_history.m

solid_motor_oscillation.pdf
Zoom FFT of a time series.
zoomFFT.m

zoomFFT_plot.m

zoom_fft.pdf
zoomFFT_example.pdf
d9p5.txt

Interpolation of a time history via its Fourier transform
interp_fourier.m

 Signal Processing Matlab Scripts
Time History, PSD, SRS & SPL Statistics & Plotting signal_stats.m

Supporting functions:

differentiate_function.m

plot_histogram.m

coordinates_ss.m

coordinates_ss_scale.m

octaves.m

PSD_octave.m

plot_peak_histogram.m
signal_stats_TH.m
signal_stats_SRS.m
signal_stats_SPL.m
signal_stats_PSD.m
Multi-function signal processing script for time histories signal_functions.m

signal_function_extract.m

signal_function_stats.m
Integrate time history via the trapezoidal rule. integrate_th.zip
This script corrects an acceleration signal so that its corresponding velocity and displacement time histories are stable and oscillate about the zero baseline disp_correction.m

enter_time_history.m
velox_correction_d.m Butterworth_filter_function.m differentiate_function.m integrate_function.m
half_cosine_fade.m
cubic_spline_function.m
fix_size.m
Differentiate a time history. differ.m
Calculate the standard deviation time history from an instantaneous time history  std_dev_th.m
Determine the natural frequency and damping of a transient waveform using time history synthesis sinefdam.m
sf_engine.m
Determine the natural frequency of a sinusoidal waveform using time history synthesis sinefind.m
sfa_engine.m
 Extract Time History Segment  extract.m
Track frequency and amplitude for a sine sweep sine_sweep_spectral.m
Find phase angle between two signals for sine sweep excitation sine_sweep_spectral_phase.m
Auto-correlation of two signals.
The Matlab Signal toolbox is not required.

auto_correlation.m

progressbar.m

Cross-correlation of two signals. 
The Matlab Signal toolbox is not required.

cross_correlation.m

Aliasing frequency calculator aliasing.m
Remove pure tone noise from a signal. Can be used to remove 60 Hz and harmonic noise.
This method uses a time domain method curve-fitting method. It is precise but may take a "long" computational time.
remove_noise_frequency.m

sfa_engine_60.m

Cubic spline

cubic_spline.m
Relative displacement between two displacement time histories relative_displacement.m

Signal Generation
Matlab Scripts
Generation of time history signals:

1=sine
2=cosine
3=damped sine
4=sine sweep
5=white noise
6=terminal sawtooth pulse
7=half-sine pulse
8=versed sine pulse
9=wavelet

generate.m
Supporting functions:

plot_histogram.m
sweep.m
white.m
Butterworth_LP_filter_function.m filter_coefficients.m
apply_filter.m
Generate a white noise time history where the user specifies the standard deviation and kurtosis.  The skewness is approximately zero.

white_kurtosis.m

progressbar.m

Generate a white noise time history where the user specifies the standard deviation, skewness and kurtosis. 

white_kurtosis_skewed.m

Supporting functions: plot_histogram.m

progressbar.m

Generate a time history with kurtosis > 3.  The corresponding histogram has a shape similar to a witch hat.
witch.m

Filtering
Matlab Scripts
Butterworth Sixth Order Filter, Transfer Function 
BH.m

filter.pdf

REFILT.pdf

Bessel Filter, Transfer Function
Bessel_H.m
Butterworth Sixth Order Filter 

Butterworth_filter.m
Supporting functions:
enter_time_history.m
filter_coefficients.m
apply_filter.m
Bessel Filter via Fourier transform
fourier_filter_Bessel.m
Bessel_Transfer.m
Butterworth Sixth Order Filter via Fourier transform
fourier_filter.m
Butterworth_Transfer.m
Mean filter of a time history
mean_filter.m
Sine Vibration
Matlab Scripts
Sine Vibration Response Spectrum (VRS)
sine_vrs.m
Time history response of an SDOF system to a sinusoidal base input sine_base.m

  Structural Dynamics: Beams & Rods
Matlab Scripts
Natural Frequencies and Mode Shapes of a Beam via the Finite Element Method, with two degrees-of-freedom per node.

This program also calculates the participation factors and effective modal mass values.
It allows for the addition of a point mass.
 beam.m

Functions:

beam_data_entry.m

local_stiffness.m
local_mass.m
assembly.m
plot_modes.m
mass_condense.m

Generalized_Eigen.m

beam.pdf  

Natural Frequencies and Mode Shapes of a Beam via the Finite Element Method with six degrees-of-freedom per node.

The beam elements may be in a three-dimensional frame.


 

beam_3D.m

Functions:

beam_3D_mass_condensation.m

Generalized_Eigen.m
beam_3D_modeplot.m

User Guide

beam_3D_guide.pdf

Normal modes & base excitation of a Cantilever Beam
cantilever_beam.m
Normal modes & base excitation of a Fixed-Free Rod
fixed_free_rod.m
Natural Frequencies and Mode Shapes of a Rocket Vehicle. The user must input a mass density file and an stiffness file. The stiffness file must be in terms of EI.
A future version of this program will allow for joint compliance and a branch for a payload.
 rocket_bending.m

Functions:

rocket_bending_data_entry.m

rocket_local_stiffness.m
rocket_local_mass.m
assembly.m
plot_modes.m
 Structural Dynamics: Plates
Matlab Scripts
Natural Frequencies of a Circular Plate, Simply-supported, Bessel Function Solution circular_SS.m
Natural Frequencies of a Circular Plate

circular_plate.m

polarplot3d.m

parse_pv_pairs.m

The Fundamental Frequency of an Isolated Circular Plate
 circular_elastic.m
Natural Frequencies of a Annular Plate  annular_plate.m
The Fundamental Frequency of an Isolated Annular Plate
 annular_elastic.m
The Natural Frequency of a Rectangular Plate Point-Supported at Each Corner
plate_corners.m
pfunction.m
  Structural Dynamics, Other Matlab Scripts
Free vibration of a single-degree-of-freedom system, exact method.  free.m
free.pdf
Free vibration of a multi-degree-of-freedom system, exact method.
mdof_free.m


Generalized_Eigen.m
plot_legend.m
line_colors.m
Natural frequenices, mode shapes, participation factors and effective modal mass values of a two-degree-of-freedom system.  two_dof.m
Natural frequenices and mode shapes of a three-degree-of-freedom system.  three_dof.m
Natural frequenices and mode shapes of a multiple-degree-of-freedom system.

mdof.m
Generalized_Eigen.m

Natural frequenices and mode shapes of a multiple-degree-of-freedom system, reduced to a subset of dof per the user's input.

mdof_reduced.m
Generalized_Eigen.m

Mass Condensation (Guyan Reduction)

mass_condensation.m
Generalized_Eigen.m

Craig-Bampton Method mdof_CB.m
The Steady-State Frequency Response Function of a Multi-degree-of-freedom System Subjected to Harmonic Base Excitation two_dof_frf.m
The Steady-State Frequency Response Function of a Single-degree-of-freedom System Subjected to Harmonic Force Excitation sdof_force_frf.m
The Steady-State Frequency Response Function of a Multi-degree-of-freedom System Subjected to Harmonic Force Excitation two_dof_force_frf.m

two_dof_force_frf_alt.m

Natural Frequency of a Single-degree-of-freedom System ( GUI )  SDOF_freq.m
SDOF_freq.fig
 Vibration Analysis of an Isolated Mass with Six-degrees-of-freedom  six_dof_iso.m 

Multi-degree-of-freedom system subjected to applied force, modal transient analysis

 

mdof_arb_force.m
progressbar.m
Generalized_Eigen.m

Multi-degree-of-freedom system subjected to applied force, modal transient analysis, reduced system

mdof_reduced_arb_force.m
progressbar.m

Matlab script for reduced system  subjected to applied force, modal transient analysis, mass condensation mdof_masscon_arb_force.m
Assembly of mass and stiffness matrices with transformation matrix

mass_stiffness_assembly.m
Generalized_Eigen.m

Natural Frequencies of Spring Mass Systems in Series spring_mass_series.m
Generalized_Eigen.m
Torsional natural frequencies of a rod or shaft rod_torsional_fn.m
Three-dimensional coordinate transformation coordinate_transformation_3D.m
Roots of characteristic equations for structural dynamics  vibration_roots.m
See also:

Matlab acoustics Page
Matlab linear algebra Page
Matlab_modal_transient_Page
Matlab_Newmark_Page

Matlab ode45 Page
Matlab RK4 Page

Matlab random vibration Page

 Material Science
Matlab Scripts
Stress Corrosion Cracking: stress required to propagate a partial through-the-thickness crack-like discontinuity
  stress_intensity.m
  Animation Matlab Scripts
 Animation of a single-degree-of-freedom system (spring mass system) subjected to sinusoidal base excitation with time history display.  SDOF_base_animation.m

 Animation of a single-degree-of-freedom system (spring mass system) subjected to sinusoidal base excitation. (old)  SDOF_sine.m

Animation of seven SDOF systems subjected to common sinusoidal base excitation.   SDOF_sine7.m
  Plot Digitization
Matlab Scripts
Digitize SRS and PSD plots from image files, such as .jpg files.
 loglog_digitize.m
Digitize log-linear plot.
loglin_digitize.m
Digitize SPL plot
digitize_SPL.m
Another digitization program.
digitize_plot.m

 

 Additional Plot Utilities
Matlab Scripts
Surface Scatter Plot from matrix with three columns of data
surface_scatter_plot.m
Plot a large time history by taking only the max and min within successive intervals.
small_plot.m
Plot EasyPlot *.sav files in Matlab
EasyPlot_translator.m

  Utilities Matlab Scripts
ASTM E 1049-85 (2005) Rainflow Counting Method rainflow.m
This progam sets up a coordinate table interactively for a PSD or SRS. coordinates.m
 Convert Matlab data to ASCII text.
These programs use syntax similar to C/C++.
 data_convert.m

 data_convert_21.m
Convert time in seconds to hours, min, sec format. hrminsec.m
Multi-format data input utility. data_input.m
Remove header lines from an external ASCII input file. header.m
UCI data conversion.

Generates a series of two-columns files (time & amplitude) from a UCI input file.

The first column is time(sec).
The additional columns are amplitude.
uci.m
Principal moment of interia from a rotational inertia matrix. principal_moi.m
Add dB values for SPLs & PSDs. add_dB.m
Calculate the arc length of a half-sine wave.
These scripts demonstrate the use of the quad function with variable coefficients.
arclength_sine.m

arc_function.m
Calculate the roots of a cubic polynomial. cubic_poly_roots.m
Interpolation
Matlab Scripts
Interpolate or extrapolate given two reference coordinates. Linear, Semilog and log options are included.
interpolate_coordinates.m
Logarithmic interpolation of a function.
intlog.m
Interpolate log-linear function.
int_semilog.m
Math & Geometry
Matlab Scripts
Calculate pi using a series expansion of
cos(theta) and by applying the Newton-Raphson method.  The goal is to find the root of
cos(theta)=-1.
pi_nr.m
Calculate pi by determining the arclength of a quarter circle.
pi_arclength.m
progressbar.m
Calculate pi by determining the area of a quarter circle.  Simple grid point integration is used.
pi_gpi.m
progressbar.m
Calculate the area of a quadrilateral which may be irregular from its coordinates quadrilateral_area.m
Calculate the area of a triangle from its coordinates. triangle_area.m
 
Statistics
Matlab Scripts
Normal tolerance intervals, upper limits
k_factor.m 
Integrate the noncentral t-distribution
noncentral_t_distribution.m 

Integrate the noncentral t-distribution, table format
noncentral_t_distribution_table.m
Integrate the student t-distribution. integrate_t_distribution.m
t_distribution.m
Integrate the chi-square curve.

integrate_chi_square.m

chi_function.m

Integrate the normal distribution curve.
integrate_normal_distribution.m
Finance
Matlab Scripts
Loan calculation script for principal and interest
loan.m

Recommended Books
Please recommend this site by clicking on the Google +1 Button.
Other Vibrationdata Pages:    Home | Tutorials