5.12. Subroutine Descriptions and Flow Charts

5.12.1. Subroutine Listing and Description

The subroutines used in the PRIMAR-4 module are listed in Table 5.12.1. The driver for the transient subroutines is PRIMAR, and the driver for the steady-state subroutines is SSPRM4.

5.12.2. PRIMAR-4 Module Flow Chart

The main subroutines in the PRIMAR-4 module are linked as shown in Figure 5.12.1.

../../_images/Module_Flow_Chart_image.svg

Figure 5.12.1 PRIMAR-4 Module Flow Chart.

Table 5.12.1 PRIMAR-4 Subroutines

Routine

Description

ANETMP

Annular element temperatures

AVGVAL

Average motor torque over a time step for centrifugal pump

BYPSTM

Temperatures of the coolant, reflectors, and duct wall for a bypass channel; called after the flow is known

CKVLFL

Check valve flow coefficients

COREFL

Estimates core channel flow

CPCPHT

Component to component heat transfer

CUTBAK

Re-initializes variables when the PRIMAR time step is cut back

CVTEMP

Liquid temperatures for a compressible volume, using a one-point perfect mixing model

DRACSF

Shell-side flow coefficients for DRACS heat exchanger

DRACTF

Tube-side flow coefficients for DRACS heat exchanger

GRVHED

Gravity head

IHXSHF

Flow coefficients for IHX shell-side

IHXTBF

Flow coefficients for IHX tube-side

INCPVF

Pressure coefficients for an almost incompressible liquid volume with no cover gas

INITST

Initializes arrays for a sub-interval

INPLNF

Inlet plenum pressure coefficients

LIQCV

Pressure coefficients for a compressible volume with no cover gas

LIQFIN

Compressible volume pressure at end of sub-interval, with liquid only and no cover gas

LQGSFN

Compressible volume pressure at end of sub-interval, with liquid plus cover gas

OUTNGF

Pressure coefficients for a compressible outlet plenum, no cover gas

OUTPLF

Pressure coefficients for an outlet plenum with cover gas

PIPEFL

Pressure coefficients for pipe flow with friction

PIPTMP

Pipe temperatures using Lagrangian mesh

PMPBLF

Pressure coefficients for a pump bowl with cover gas

PMSTRT

Initializes arrays for a sub-interval

POOLFL

Pressure coefficients for a pool

PRESDR

Pressure drop in a flow element

PRIMAR

Main driver for the module

PRIMR1

Simple PRIMAR-1 option, with user-specified driving head vs. time, or flow vs. time

PRMADJ

Adjusts inlet and outlet plenum variables to account for the differences between estimated and computed channel flows

PRMEND

Puts final sub-interval results into permanent arrays for storage

PRMPRT

Prints PRIMAR-4 results

PRSRZF

Pressure coefficients for a pressurized (expansion tank)

PRSTEP

Finds the next PRIMAR time-step size or decides to cut back the current step size

PUMPFL

Pump head and flow coefficients

PUMPFN

Pump impeller speed and head calculation at the end of a sub-interval

RUPSKF

Pressure coefficients for a pipe rupture sink, guard vessel with cover gas

RUPSRF

Pipe rupture source pressure coefficients

SELECT

Chooses average and final inlet/outlet temperature into/from a compressible volume, according to segment flow directions

SSADHX

Steady-state air dump heat exchanger

SSBYPS

Bypass channel steady-state coolant and wall temperatures, given steady-state flow rate and steady-state power

SSCKVL

Steady-state check valve pressure coefficents

SSCPNL

Steady state null transient driver

SSIHX

Steady-state IHX temperatures

SSIHXC

Steady-state IHX temperatures, simple model

SSLQSG

Steady-state initialization of the elements in a liquid segment

SSPMLP

Steady-state initialization of primary loop flows, pressures, and temperatures

SSPRM4

Steady-state initialization of PRIMAR-4 variables – driver for the steady-state routines

SSPRPL

Initilization for file 15 binary output

SSPRSR

Steady-state pressure and pump head for one segment of an intermediate loop

SSPUMP

Steady-state initialization of pump parameters

SSP4PR

Steady-state PRIMAR-4 printout

SSP4TH

Initialization of node volumes, VOLNDT(ITGP), coolant and wall temperatures, and liquid and wall temperature arrays for pipe-type temperature groups

SSSCLP

Steady-state initializaton of the intermediate sodium loops, and also calls the steam generator initialization routines

SSSTDR

Steady-state steam generator driver

SSSTGN

Steady-state steam generator initialization of simple table look-up option

SSVALV

Steady-state valve pressures

STEPFN

Finishes liquid flows and temperatures for a sub-interval

STEPGS

Gas flow between compressible volumes and storage tanks for a sub-interval

STEPLQ

Driver for liquid flow and pressure calculations

STEPTM

Driver for liquid temperature calculations

STGNFL

Steam generator flow coefficients, sodium side

STRATV

Stratified volume calculations

STRGVH

Calculates gravity heads in a stratified volume

SUBSIZ

Sets the PRIMAR time sub-interval size

TSDRCS

DRACS temperatures

TSIHX

IHX temperatures, shell and tube sides, and gravity head

TSIHXC

IHX temperatures and gravity head, simple model

TSPRPL

Writes binary arrays to file 15 for later use

TSSTGN

Steam generator temperatures and gravity head, simple model

VALVAJ

Steady-state valve pres. drop adjustment. If needed, between compressible volumes connected by several liquid segments

VALVFL

Valve pressure coefficients