| ggarciabas (1) | |||
|
Hello, I created a simple file to calculate a bisection and I had problems with the #define. I used this structure:
And in the function bisseccao () I have fa, a simple variable and I want that variable receive the result of the f1a ( defined on #define), but the result is wrong. This is correct? If not, could some one help me, I need to do something like this, I need to inform the equation and calculate them. Thank you, GGarciaBas | |||
|
|
|||
| kbw (5371) | |
| That isn't quite right in principle. But rather than wasting time fixing that, as you're using C++, why not use functions? You can inline them if you feel you need them to be inline. | |
|
|
|