I am having a bit of a problem trying to understand while loop.
I was given a question lke this
Write a while loop to evaluate the spl of effective pressure p starting from pref and increasing by a factor of 2 at a time.The program should stop when the spl exceeds 100 db.The output should clearly show p and spl at each step
But it keeps making matlab crash by giving me an infinite loop.
The Attempt at a Solution
My code was like this