Welcome to the new platform of Programmers Heaven! We apologize for the inconvenience caused, if you visited us from a broken link of the previous version. The main reason to move to a new platform is to provide more effective and collaborative experience to you all. Please feel free to experience the new platform and use it's exciting features. Contact us for any issue that you need to get clarified. We are more than happy to help you.
Help with Fortran and C++ please
I'm a beginner in programming, but I need to manage a program which is written in fortran and c++ (two different sections). I'm working (until now) with g95 for the fortran section and with Intel C++ for the C++ part. Unfortunately, at least now I need to work in windows.
Following the instructions of the manuals I tried to compile both parts of the program and I couldn't.
Compiling with g95, I started writing the command: g95 -c program.f, but it lead to lots of errors. I realised that that the program was using some instructions for c++, and I changed the command to:
g95 -cpp program.f
It returned the error:
>>In file program.f: 9383
>>Error: Invalid form or array reference at (1)
The program has already worked for other people, so I don't know where is the problem.
With the C++ part, I tried to compile it with Intel C++ compiler, using the command: icl program.cpp and I had this error:
>>icl: warning #10114: Microsoft Visual C++ not found in path
>>program.cpp(25): catastrophic error: could not open source file >>"iostream"
>>compilation aborted for program.cpp (code 4)
I guess I'll need to reinstall the Microsoft Visual C++, but I don't understand very well the problem with iostream.
Thank you in advance for any help you could give me