Continue to Site

Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

  • Congratulations MintJulep on being selected by the Eng-Tips community for having the most helpful posts in the forums last week. Way to Go!

How to define a body flux and a surface flux with user subroutine DFLUX at the same time?

Status
Not open for further replies.

yjmp14

Materials
Apr 27, 2016
1
I want to heat a object with a surface flux and a body flux at the same time.
How can I achieve this purpose with user subroutine DFLUX?

Now I have write a surface flux and a body flux with DFLUX and thay work well separately, but how can I write them in one file and let them work together.

I tried to write the subroutine like this:

Code:
IF (JLTYP.EQ.1) THEN
    Code for body flux...
END IF

IF (JLTYP.EQ.0) THEN
    Code for surface flux...
END IF

But it doesn't work correctly, when I run this subroutine, only the surface flux work, the body flux just doesn't work.

PS. I have set a surface flux and a body flux at Loads module and both select User Define.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor