CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   Siemens (https://www.cfd-online.com/Forums/siemens/)
-   -   How to deal with the user subroutine problem? (https://www.cfd-online.com/Forums/siemens/55346-how-deal-user-subroutine-problem.html)

Jim May 11, 2006 14:47

Re: How to deal with the user subroutine problem?
 
This logic doesn't work - the coding may not fail on its own, but if you remove the user-coding from STAR, no doubt it won't crash either.

A few points:

1. Are you sure it's the data statements - ie. have you removed all other coding from the routine and does it still crash?

2. you say that your data statements are very long. How many characters are there on any one line? Some compilers don't like long lines. Try the same code, but with a small array (e.g. array(1:2)). It's very unlikely that it's just that STAR "doesn't do data statements".

3. Try printing the array. You may find that some of it's OK, then it crashes halfway through printing the array. This would suggest that it's not being assigned correctly.

4. Go on a diplomacy course. There are a lot of people in this forum who have done a lot of very complex user-coding with STAR. The power of its user-coding is one of the reasons why it's the second most used CFD code in the world. Giving up and assuming it's a bug is the easy option, but generally not the right one.

Your test of compiling the code on its own is one approach, but not the definitive one. User-coding isn't the same as compiling a program on its own, for example STAR uses a whole host of compiler flags, and the routine is being called from a large and complex program. User-coding can be more demanding than writing a program on its own, because if you allocate an array incorrectly it can overright something that you kidda needed, whereas you can get away with it in a standalone program.

5. Good luck. Complex user-coding can be hard work, but remember that's because it's complex, not because user-coding in STAR is buggy. It isn't. As has already been said, you invariably end up making a change in your code rather than submitting a bug.

Richard May 19, 2006 09:30

Re: How to deal with the user subroutine problem?
 
Particle - do you have any news for us about this problem?


All times are GMT -4. The time now is 07:27.