Ramp Function in MATLAB? also window adjustments (MATLAB Help)

AI Thread Summary
A user is seeking assistance in MATLAB to create a ramp function that gradually transitions from 0 to 1, which is needed to filter an earthquake chirp signal for a project related to nuclear bomb detection. They have attempted to modify a unit step function using conditional statements but have not achieved the desired outcome. Additionally, they are struggling with adjusting the graph window, as outliers in their data skew the range, complicating visualization. The user expresses frustration over the manual process of removing outliers. Overall, the discussion focuses on creating a ramp function and managing data visualization challenges in MATLAB.
Luongo
Messages
119
Reaction score
0
1. I produced a unit set function in MATLAB however my professor requires me to use a ramp function to be multiplied to a signal to filter out unnecessary parts of an earthquake chirp, this is being used in my project to determine whether the chirp was caused by a nuclear bomb.



2. ideally i'd like something similar to a unit step function but it doesn't go from 0 to 1 immediately, preferably in a linear fashion.



3. I tried modifying my unit step function but i haven't had any luck using conditional statements yet... I get the same result.
Just an aside question for MATLAB, how do i adjust the window. i can set the domain, however the range gets skewed if there's an outlier in my data that goes off to infinity my entire graph gets screwed up unless i delete the outliers by hand, which is a pain especially since there are many of them. Thanks!
 
Physics news on Phys.org
well i have the unit function but it goes from 0 to 1 with a ramp between that range
 
thanks a lot for the help, assholes
 
Thread 'Variable mass system : water sprayed into a moving container'
Starting with the mass considerations #m(t)# is mass of water #M_{c}# mass of container and #M(t)# mass of total system $$M(t) = M_{C} + m(t)$$ $$\Rightarrow \frac{dM(t)}{dt} = \frac{dm(t)}{dt}$$ $$P_i = Mv + u \, dm$$ $$P_f = (M + dm)(v + dv)$$ $$\Delta P = M \, dv + (v - u) \, dm$$ $$F = \frac{dP}{dt} = M \frac{dv}{dt} + (v - u) \frac{dm}{dt}$$ $$F = u \frac{dm}{dt} = \rho A u^2$$ from conservation of momentum , the cannon recoils with the same force which it applies. $$\quad \frac{dm}{dt}...
I was thinking using 2 purple mattress samples, and taping them together, I do want other ideas though, the main guidelines are; Must have a volume LESS than 1600 cubic centimeters, and CAN'T exceed 25 cm in ANY direction. Must be LESS than 1 kg. NO parachutes. NO glue or Tape can touch the egg. MUST be able to take egg out in less than 1 minute. Grade A large eggs will be used.
Back
Top