CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > OpenFOAM > OpenFOAM Programming & Development

How to create a function object in OpenFoam that runs properly ?

Register Blogs Community New Posts Updated Threads Search

Like Tree2Likes
  • 2 Post By wyldckat

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   October 3, 2018, 12:14
Default How to create a function object in OpenFoam that runs properly ?
  #1
Member
 
K
Join Date: Jul 2017
Posts: 97
Rep Power: 9
mkhm is on a distinguished road
Dear foamers,



I want to implement a new function object. This one is very similar to the reactionSensitivityAnalysis available in the Openfoam version 1806. As I have my modified solver in OpenFoam 4.x. I wanted to first compile this function object reactionSensitivityAnalysis in openfoam 4.x. and after modify it. I don't have any errors when compiling it. However, when I include the lib in the controlDict:


Code:

functions
{
    reactionSensitivityAnalysis
    {
        libs                ("libmyFieldFunctionObjects.so");
        type                psiReactionThermoMoleFractions;//psiReactionsSensitivityAnalysis;
        writeControl        writeTime;
    }
}
I have following warning :




Code:

   69 Courant Number mean: 1.46699e-05 max: 0.000942628
  70 --> FOAM Warning :
  71     From function bool Foam::functionObjectList::read()
  72     in file db/functionObjects/functionObjectList/functionObjectList.C at line 671
  73     Caught FatalError


  74 --> FOAM FATAL ERROR:
  75 Unknown function type psiReactionsSensitivityAnalysis
and postProcessing folder is not created.



Could you please help me ? This function Object functioning becomes a real mystery to me. Could someone explain how these postProcessing tool of openFoam work ?[COLOR=inherit !important]


mkhm is offline   Reply With Quote

Old   October 20, 2018, 17:16
Default
  #2
Retired Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,981
Blog Entries: 45
Rep Power: 128
wyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to allwyldckat is a name known to all
Quick answer:
  1. Run the following command inside the main folder of your modified source code:
    Code:
    wclean
  2. Then package the whole folder of your modified source code.
  3. Then attach it to your next post, so that it's a lot easier and faster to diagnose the problem.
Because there are too many possible reasons for this to not work, based on the information you've provided. My best guess is that you're not using the correct type name, because it has to be the exact same name that is defined in the ".H" file, in the line where "runtime" type is defined.
__________________
wyldckat is offline   Reply With Quote

Reply

Tags
functionobject, openfoam 1806, openfoam 4.x, postprocessing


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Map of the OpenFOAM Forum - Understanding where to post your questions! wyldckat OpenFOAM 10 September 2, 2021 06:29
OpenFOAM v3.0+ ?? SBusch OpenFOAM 22 December 26, 2016 15:24
[foam-extend.org] Error compiling OpenFOAM-1.6-ext Canesin OpenFOAM Installation 137 January 20, 2016 15:56
ParaView for OF-1.6-ext Chrisi1984 OpenFOAM Installation 0 December 31, 2010 07:42
fluent add additional zones for the mesh file SSL FLUENT 2 January 26, 2008 12:55


All times are GMT -4. The time now is 13:36.