Error: undefined in dictionary ...fvsolution.solvers
Hello
I have coded a new solver based on interFOAM, the new solver gets wmake(ed) fine, no errors. When I want to run a case with the solver I get the error as --> FOAM FATAL IO ERROR: keyword H is undefined in dictionary "/home/Dropbox/OpenFoam/system/fvSolution.solvers" file: /home/Dropbox/OpenFoam/system/fvSolution.solvers from line 22 to line 63. From function const Foam::dictionary& Foam::dictionary::subDict(const Foam::word&) const in file db/dictionary/dictionary.C at line 642. FOAM exiting I am confused since "H" should not appear in my "fvsolution" file, it is just a parameter coded in my solver, so I believe there should not be a requirement for a keyword as H. Can you give me a hint on how to find the problem and resolve the issue? If you want I can even send you the new solver that I have written for your review. Thanks |
Actually now I just define H in the "fvsolutions" similar to say "U" as
Code:
H My surprise is that, why there should be the need for defining H, because H in my solver is not solved actually and it is defined, it is basically a Heaviside function, so no need for specifying solver. Probably I have messed up somewhere and that's why OF considers H as a parameter that needs to be solved, but I cannot find out where I have made this mistake. Any hints helping to find this bug would be appreciated. Thanks :) |
Hi,
Far from being an expert :D, did you set up H in createFields ? How is it coded in the solver.C file ? |
in createfields.H it is as
Code:
Info<< "Reading field H\n" << endl; Code:
// update Heaviside function |
Hi all,
@akesm And these are the only additions you have made? Is there a possibility that as a result of copy-paste you have another field named H in registry for which you actually solve linear equation? (variable name for the field in your solver could be named differently). |
Thanks for your reply.
But my new solver is based on interFoam, which does not have any field named as H, so I barely think that my introduced parameter H is being mistaken with an already existing field named as H. If it helps I can post, or upload either my solver or the changes I have made! |
Well, it YOU, who has strange behaviour of new solver. So it is up to YOU to decide either you are happy with small addition to fvSolution file, or you would like to resolve this problem. Either the thread can be closed, or you post a link to your repository with code, so people can take a look and figure out why OpenFOAM(TM) needs addition to solvers dictionary in fvSolution file (and maybe propose solution).
|
Now when I am looking carefully, at a point of my code I give H to explicit solve in the way below
Code:
MULES::explicitSolve(H, phi, phiH, 1, 0); |
All times are GMT -4. The time now is 07:22. |