Search:

Type: Posts; User: CodeKate

Page 1 of 3 1 2 3

Search: Search took 0.01 seconds.

  1. When you say, "just compile all the .cpp files":...

    When you say, "just compile all the .cpp files": if the statement that works to compile the single main.cpp file is:

    gcc main.cpp -o myExecutable

    ...what would your suggested alternative...
  2. Thanks for the additional input. Given my...

    Thanks for the additional input. Given my previous good experiences with GCC, and cyberfish's caution about the Intel compiler, I'm planning to stick with the GCC compiler. I just learned that one of...
  3. Thanks for your input, Elysia & grumpy. Yes, the...

    Thanks for your input, Elysia & grumpy. Yes, the Gnu compilers include GCC. I think I'm going to give the GCC a try, and I'll be sure to confirm that the code remains functional with the new compiler.
  4. Thanks for the suggestion, bernt. I made this...

    Thanks for the suggestion, bernt. I made this change, and recompiled the code; it worked! That's definitely a good sign. I suppose that my next step is to try compiling the code on the cluster, using...
  5. Compiling Visual C++ code using a different compiler

    I have a system of C++ code that was written using Visual C++ 2008 Express Edition. I need to run this code on a high-performance cluster that doesn't allow compilation with Visual C++; instead, the...
  6. Sorry about that. I'll try to avoid such...

    Sorry about that. I'll try to avoid such omissions in future posts. :)
  7. Ok, that was my initial belief about the action...

    Ok, that was my initial belief about the action of calling fabs(). However, I still don't understand why my third condition in my OP wasn't executing:



    if(Lq[j] >= 0.005) Lq_sign = 1.0; ...
  8. Yes, that is intentional, Tater, but thanks for...

    Yes, that is intentional, Tater, but thanks for pointing it out. I clear and reuse that variable each time through the loop.
  9. Aha! I hadn't been aware that calling fabs( ) was...

    Aha! I hadn't been aware that calling fabs( ) was actually *changing* the value!

    Here is my revised code, which now does work:



    if(Lq[j] >= 0.005) Lq_sign = 1.0;
    else if((Lq[j] > -0.005) &&...
  10. Weird problem -- negative doubles not being processed by my code

    I'm trying to write a very basic if() conditional statement, which in its ideal/simplest form, should look like this:




    double Lq[5] = {0.0};
    double Lq_sign = 0.0;

    /* call function to...
  11. Replies
    13
    Views
    2,693

    Great observation; I'll keep that in mind as I...

    Great observation; I'll keep that in mind as I work to implement the rest of my functions.
  12. Replies
    13
    Views
    2,693

    My specific error message is: CMEXsfcn.c(312) :...

    My specific error message is:
    CMEXsfcn.c(312) : error C2440: 'function' : cannot convert from 'double' to 'double *'

    The problematic function call is:

    getActionWrapper(*temp830, *actionBuff,...
  13. Replies
    13
    Views
    2,693

    Thanks for your suggestion, Tater. I did add your...

    Thanks for your suggestion, Tater. I did add your code, and I see that, apparently, my compiler *does* recognize the bool type. The compile error that I now receive is:

    error C2371: 'bool' :...
  14. Replies
    13
    Views
    2,693

    My concern is that I'm using Matlab R2009b & the...

    My concern is that I'm using Matlab R2009b & the associated version of Simulink, and I need a compiler that is specifically compatible with this version. This is the official list: Support -...
  15. Replies
    13
    Views
    2,693

    Thanks for your input, Salem & anduril. ...

    Thanks for your input, Salem & anduril.



    The 2 sections of code I posted above are in the same order in my actual code, i.e. the 2nd section immediately follows the first, and I don't see any...
  16. Replies
    13
    Views
    2,693

    Syntax question about c-mex s-functions

    I'm creating a c-mex s-function that calls functions from an existing library. However, due to the way that the code is set up, I need to perform an extra step when calling these functions, by...
  17. yeah, thanks. It's not that I was unfamiliar with...

    yeah, thanks. It's not that I was unfamiliar with header files, but just that there were already a number of them included in my code, and I wasn't sure if others were missing...


    Thanks a lot!
  18. Update: just by including the and...

    Update: just by including the <windows.h> and .dll header call (duh), as Tater suggested, the code is now compiling successfully with no warnings. This isn't necessarily the end of my issues, but is...
  19. Thanks for your input, Tater. You've given me a...

    Thanks for your input, Tater. You've given me a lot to consider.
  20. Ok, I reviewed the source code specifically for...

    Ok, I reviewed the source code specifically for my DLL, and it *does* start with 'extern "C" '. I should mention that both the example code/.dll as well as the real versions of those files, were...
  21. Thanks for bringing that issue to my attention,...

    Thanks for bringing that issue to my attention, Tim. I'm almost certain that the .dll was written in C++. Do you know how I would determine, for certain, whether this poses an insurmountable problem...
  22. Additional info: Compiler errors

    In case it's useful, I'll paste below the list of compiler errors I get, when I attempt to create a mex file using my current C code (with corrected comment indicators) and a related .lib file:
    ...
  23. Converting simple C++ example to C, to use existing DLL

    I'm attempting to use an existing .dll file from within my C code. My coworker who created this .dll has a simple example written in C++ that uses this file, which example code I'm able to use with...
  24. Replies
    6
    Views
    2,400

    Thanks for your suggestion. I tried this, and...

    Thanks for your suggestion. I tried this, and unfortunately it didn't solve the problem. But it's probably good practice for me to consistently use %lf, anyway...
  25. Replies
    6
    Views
    2,400

    >> You could use a static analysis tool as an aid...

    >> You could use a static analysis tool as an aid to discover potential problems

    Thanks for the suggestion... I wasn't familiar with static analysis tools before your post, but I see that there is...
Results 1 to 25 of 67
Page 1 of 3 1 2 3