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

customize semiImplicitSource

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 25, 2022, 10:46
Default customize semiImplicitSource
  #1
Member
 
chen112p's Avatar
 
Junting Chen
Join Date: Feb 2016
Location: Ontario Canada
Posts: 38
Rep Power: 10
chen112p is on a distinguished road
Hello, I am trying to add some custom features to semiImplicitSource library. However, without touching the core parts of the code, FOAM couldnt read the new library for some reasons. Hope someone can help me with this.

So I first copied the source code (the entire src/fvOptions to be safe) to somewhere other than $FOAM_SRC. Then I changed $FOAM_LIBBIN in Make/files to $FOAM_USER_LIBBIN and removed the unnecessary items in files. Then I changed type name in SemiImplicitSource.H to something other than "SemiImplicitSource" (ie. jtSemiImplicitSource) so when I call this library I know I'm not calling the original one.

Compile went ok (because technically I didnt change anything), but when adding the new type to fvOptions, FOAM tells me the new type name Im using (ie. scalarjtSemiImplicitSource) is not found.

Can someone tell me what is missing here?

jt
chen112p is offline   Reply With Quote

Old   June 27, 2022, 05:45
Default
  #2
Senior Member
 
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,715
Rep Power: 40
olesen has a spectacular aura aboutolesen has a spectacular aura about
If your library loads properly, it sounds like you forgot to register your sources.


Eg,
Code:
makeFvOption(SemiImplicitSource, scalar);
olesen is offline   Reply With Quote

Old   December 7, 2024, 08:41
Default
  #3
New Member
 
likun
Join Date: Dec 2024
Posts: 1
Rep Power: 0
ouqiyo is on a distinguished road
Hello, I have recently encountered this problem, also just change SemiImplicitSource to mySemiImplicitSource in the file name and SemiImplicitSource to mySemiImplicitSource in the content of the file, it compiles successfully, but when using it I can't load the library. It compiles successfully, but when I use it, I can't load the library in fvoptons, besides, the code makeFvOption(SemiImplicitSource, scalar); exists in the original file, may I know how else to solve it?
ouqiyo is offline   Reply With Quote

Reply


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
Customize the Prandtl number in the k-epsilon mode ClydeL FLUENT 5 November 20, 2021 23:11
fvOptions: Time dependent semiImplicitSource uosilos OpenFOAM Running, Solving & CFD 1 July 2, 2021 05:12
Modify SemiImplicitSource for time varying source ksgr OpenFOAM Running, Solving & CFD 0 August 20, 2020 11:21
how to customize the initial velocity and temperature field? gdtiaozi FLOW-3D 1 December 3, 2013 08:13
Can I Customize Fluent Environment venugopal FLUENT 0 June 16, 2004 13:15


All times are GMT -4. The time now is 08:34.