CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > ANSYS > CFX

Simple Programming

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 10, 2005, 19:24
Default Simple Programming
  #1
RK
Guest
 
Posts: n/a
Hi,

I need to calculate two things: (C5=SCAL1, C6=SCAL2)

(1) pH=-log10(R*C5)

(2) R=f(pH,C6)

As written below the value of R is only known at the first node, but some value at others; using this approach the calculations are WRONG! Can someone offer a solution as to how one can wirte this simple code? (Since R is a variable, specifying within the loop as a constant defeats the purpose of the calculation)!

Hope someone can help (and thanks for your help).

SUBROUTINE USRINT

CALL IPALL(BLAH...)

pH=value1 R=value2

DO 101 I=1,NPT

INODE=IPT(I)

C5=MAX(SCAL(INODE,IPHASE,ISC1),SMALL)

C7=MAX(SCAL(INODE,IPHASE,ISC2),SMALL)

r=MAX(USRGR(INODE,IPHASE),SMALL)

C5= VALUE3

C6= VALUE4

C7= VALUE5

pH= -LOG10(r*C5)

C10= pH

r= f(pH,C5,C7)

100 CONTINUE

  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
SIMPLE algorithm in 3D cylindrical coordinates zouchu Main CFD Forum 1 January 20, 2014 17:02
How to add correcting pressure equation in SIMPLE of MRFSimpleFOAM? renyun0511 OpenFOAM Programming & Development 0 November 4, 2010 01:38
compressible SIMPLE method fakor Main CFD Forum 1 August 30, 2010 11:21
PISO vs. SIMPLE benedikt flurl Main CFD Forum 2 April 14, 2005 06:54
flow over a 2D cyl using SIMPLE T Main CFD Forum 1 January 27, 2001 07:32


All times are GMT -4. The time now is 00:14.