VPOD 3DOF Vibratory Device
Nondimensional 3DOF Bouncing Ball Simulator
Introduction
The Nondimensional 3DOF Bouncing Ball Simulator is a simple Matlab program meant to mimic the behavior of a bouncing ball on a vibratory device capable of sinusoidal motion in three degrees, such as the VPOD. The simulator uses a numerical method in which the equations of motion describing the ball's flight are determined from the state variables of the previous impact. The program uses a binary search to locate the time at which the ball's position in the x,z plane is equal to that of the oscillating bar. In short, it calculates the intersection of a parabola with a sinusoid, uses a simple impact model to compute the new state variables, and repeats this computation as many times as desired. The equations of motion for the oscillating bar are as follows:
where A_x, A_z, A_theta represent the maximum x, z, and angular displacements of the bar's motion. The key input variables are the three position amplitudes, three frequencies, and three phase angles, as well as coefficients of restitution in the normal and tangential directions.
Quick Start
In order to run the simulator, first download the Matlab files by clicking on the link below:
Description of Functions
The zipped folder contains 6 m-files:
- bBallSim - This is the main m-file and likely the only one you will have to worry about. It contains a big for loop which takes the initial conditions for the ball's flight and calculates one bar impact, storing the data in the matrix 'P'. The post-impact conditions then become the new initial conditions. It loops as many times as indicated.
- calculateIntersection - Uses a binary search method to locate the time where in ball intersects the bar, based off of the initial flight conditions and parameters. It returns the time of intersection (denoted 't2').
- checkLocking - Determines whether or not the ball is locking. Locking is a phenomenon in which the ball's velocity decays to zero, undergoing an infinite number of bounces in the absorbing region of the bar's motion. If the flight time is less than an arbitrarily small value, the ball is determined to be locking, and a value of 1 is returned.
- impact - This function takes the initial conditions and time of impact as inputs. It uses a simple impact model to calculate the post-impact positions and velocities of the ball.
- calculateLaunch - Determines whether or not the ball will be relaunched after locking. If the motion of the bar, and the position of the ball are such that the vertical acceleration of the bar will exceed gravity at some point during its periodic motion, then the ball will be relaunched. Otherwise, the ball will never be relaunched, and the simulation will terminate.
- plotTraj - This function is used only to plot the trajectories of the ball and the bar. This is only used as a visual aid and is helpful for debugging. It can easily be turned off to speed up the simulation.
Explanation of Important Inputs & Parameters
First, open the bBallSim m-file. The first few lines will look like this:
function [P, N] = bBallSim(A_z, A_th, e_n, e_t, phi) % SYSTEM PARAMETERS num_impacts = 100; % Number of impacts simulator will calculate before terminating plotting = 1; % 0 or 1 depending on whether trajectory plots are desired % not recommended for long simulations (>5000 impacts) or sweeps off = pi-phi; Amp = [0; A_z; A_th]; % Position amplitude of bar [A_x, A_z, A_th] Phase = [0; off+phi; off/2]; % Phase angle of bar [phi_x, phi_z, phi_th] f = [2; 2; 1]; % Frequencies of bar motions [f_x, f_z, f_th] w = 2*pi.*f; % [w_x, w_z, w_th] % INITIAL CONDITIONS / INITIALIZATIONS initCond = [0, 0, 0, 0, 0.1223, 0]; % [t0, x0, z0, Vx0, Vz0, locked]
There are five important inputs for this version of the program.
- A_z is the nondimensionalized position amplitude of the bar in the z (vertical) direction.
- A_th is the amplitude in the theta direction (angular about the y). It is already dimensionless.
- e_n is the coefficient of restitution in the normal direction. This can be between 0 and 1, but it should be noted that if e_n is too small the ball will not bounce. 0.75-0.95 is a good range of values for e_n if period 1 behavior is desired.
- e_t is the coefficient of restitution in the tangential direction. The simulator is functional for all values of e_t between 0 and 1.
- phi is the relative phase (offset) between the z motion and the angular motion.