To write a function in MATLAB that equates two equations, you can use the solve
function. Here's an example of how to write the function:
main.m400 chars14 lines
You can call this function by passing in two equations as input arguments. Here's an example of how to use it:
main.m216 chars10 lines
This will output the values of x
and y
that satisfy both the equations eq1
and eq2
.
gistlibby LogSnag