필터 지우기
필터 지우기

Is this event detection correct

조회 수: 1 (최근 30일)
Sreedhar
Sreedhar 2015년 4월 27일
댓글: Chad Greene 2015년 4월 27일
Hi I am solving a problem involving the expansion and contraction of a bubble in response to a sinusoidal pressure, Pa sin (wt). (Rayleigh Plesset equation)
The formula for pressure of the gas in the bubble during expansion (isothermal expansion - gamma = 1) is different from that during contraction (adiabaic compression - gamma = 1.33).
To change the formula I am using 'EVENTS' to detect the end of contraction (event 1) and end of expansion (event 2).
The bubble starts contracting initially from a radius R0 = 1e-4 m.
The condition used to detect end of contraction is : radial velocity Rdot is negative and increasing to zero
The condition used to detect end of expansion is : radial velocity Rdot is positive and decreasing to zero.
The initial condition is : R0 = 1e-4 and Rdot = 0
------------------- When I run this program I am getting 4 events. I was expecting only 2 (first after compression and second after expansion). Why is this happening ? How can I overcome this ?
Is this method of detecting event correct ? Since the radius never becomes zero I cannot use zero detection of radius as a condition.
The files used are attached :
RP7.m - is the main script file
eventsFuncn1.m is the events function
zdot7.m is the function giving the derivative
THANKS IN ADVANCE
  댓글 수: 1
Chad Greene
Chad Greene 2015년 4월 27일
Looks like the files didn't get uploaded. But realistically, you may have trouble getting a response if you upload multiple files and hope someone will sort through them.
Without having your files though, would an amplitude envelope do what you need? This could be done with a moving rms, or either of the methods discussed here.

댓글을 달려면 로그인하십시오.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Standard File Formats에 대해 자세히 알아보기

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by