Looking for help solving transcendental equations in Matlab. Here's an equation for example:
1/2 = cos(x)cos(2x) ; 0<=x<=pi/2 solving for x:
x = acos((1/2)(sec(2x))
I have tried using intersect() along with various other Matlab functions. It's easy to see an approximate value of ~.48 when I plot using the following code:
x = 0:(pi/2)/1000:pi/2;
f = @(x) (1/2)*acos((1/2)*sec(x));
plot(x,f(x));
How can I have Matlab return the value where x == f(x) within a certain tolerance?