Outline of this page
This is the room to save Fortran90 programs related engineering problems.
This is the room to save Fortran90 programs related engineering problems.
Filename | Description |
---|---|
f90_MARSTON.txt | Program to calculate the vertical load for embedded pipe by Marston's formula. |
tex_marston.pdf | Small document for Marston's formula |
Filename | Description |
---|---|
en_TeX_ams.pdf | Document of calculation formulas for critical buckling pressure |
f90_AMS_org.txt | program for calculation of Buckling pressure (Amstutz original 1970) |
f90_AMS_JPN.txt | program for calculation of Buckling pressure (Standard in japan) |
gpl_AMS.txt | script for gnuplot |
fig_AMS_org.png | sample figure (effect of initial imperfections by Amstutz) |
fig_AMS_JPN.png | sample figure (comparison between Amstutz original and JPN standard) |
!Lorentz type+linear curve (mpara=5) input file: inp_SIMP_0.csv Vfunc=param(2)*param(1)**2.0D0/((x-param(0))**2.0D0+param(1)**2.0D0)+param(3)+param(4)*x
!Damped oscillation (mpara=4) input file: inp_SIMP_1.csv Vfunc=param(0)*exp(-param(1)*x)*sin(param(2)*x+param(3))
001 | Simplex_test_1 002 | time_(sec),Displacement_(mm) 003 | N,0,800,100,"%.0f" 004 | N,-10,10,2,"%.0f" 005 | 800 006 | 0.000,2.543 007 | 1.000,3.402 008 | 2.000,2.978 ..........
For execution of this program 'f90_SIMPLEX.exe,' (1) input filename, (2) output filename, (3) image output filename for gnuplot and (4) initial values of unknown parameters for Simplex method must be inputted from command line.
gfortran -o f90_SIMPLEX.exe f90_SIMPLEX.f90 f90_SIMPLEX inp_SIMP_0.txt out_SIMP_0.txt fig_SIMP_0.png 1 1 1 1 1
Filename | Description |
---|---|
f90_SIMPLEX.txt | program for curve fitting by Simplex method |
inp_SIMP_0.txt | Sample of input data (1) |
out_SIMP_0.txt | Sample of output data (1) |
fig_SIMP_0.png | Sample drawing of result (1) |
inp_SIMP_1.txt | Sample of input data (2) |
out_SIMP_1.txt | Sample of output data (2) |
fig_SIMP_1.png | Sample drawing of result (2) |
KN No.1 Headrace ST (Load interception) Hg,Q0,L,d0,c,Cd,zm,xc,yc 713,340,2553.370,8.2,0.179,0.9,35,4.6,17
Hg | Total head (m) |
Q0 | Maximum discharge (m3/s) |
L | Length of the pressure tunnel (m) |
d0 | Diameter of the pressure tunnel (m) |
c | Head loss coefficient |
Cd | Discharge coefficient of the port |
zm | Target maximum water level given by designer (m) |
xc | Selected diameter of the port (m) |
yc | Selected diameter of the shaft (m) |
gfortran -o f90_surgeSCVF.exe f90_surgeSCVF.f90 f90_surgeSCVF inp_scvf_Load.csv fig_scvf_Load_SC.eps fig_scvf_Load_VF.eps
Filename | Description |
---|---|
en_TeX_SURGE.pdf | Document for Design of Restricted Orifice Surge Tank |
f90_surgeSCVF.txt | program for basic design of Restricted Orifice Surge Tank |
inp_scvf_Load.txt | sample input data (load interception) |
fig_scvf_Load_SC.png | sample figure (stability condition: load interception) |
fig_scvf_Load_VF.png | sample figure (maximum water level: load interception) |
KN No.1 Tailrace ST (Load interception: 4 units) //: Title 1,70.0,210.0 //: ICT,AFCA,AFCT 600.0,0.01,0.1 //: TMAX,dt,DTWR 18.857,0.9,0.9 //: PAA,PCI,PCO 814.000,2167.752,52.810,0.166 //: RWL,TNL,TNA,TNC 3 //: NST 520.000,865.000,Top_of_Surge_Tank //: SAA(1),SEL(1),SLB(1) 520.000,854.050,Bottom_of_Chamber //: SAA(2),SEL(2),SLB(2) 78.540,727.600,Bottom_of_Surge_Tank //: SAA(3),SEL(3),SLB(3) 3 //: NQT -340,0 //: QTQ(1),QTI(1) 0,8 //: QTQ(2),QTI(2) 0,9999 //: QTQ(3),QTI(3)
Title | Title |
ICT | Calculation case (1: normal, 2: AFC) |
AFCA | Discharge of half amplitude of AFC (m3/s) |
AFCT | Period of AFC (s) |
TMAX | End time for calculation (s) |
dt | Time increment for calculation (s) |
DTWR | Time increment for print out (s) |
PAA | Section area of port (m2) |
PCI | Discharge coefficient of port for in-flow |
PCO | Discharge coefficient of port for out-flow |
RWL | Water level at reservoir (EL.m) |
TNL | Length of pressure tunnel (m) |
TNA | Section area of pressure tunnel (m2) |
TNC | Head loss coefficient of pressure tunnel (s2/m) |
NST | Number of sections |
SAA(i) | Section area of specified level in the shaft (m2) |
SEL(i) | Level definition of sections of shaft (EL.m) |
SLB(i) | Label for section (text: for drawing) |
NQT | Number of discharge input points |
QTQ(i) | Discharge at specified time point (m3/s) |
QTI(i) | Time at specified time point (s) |
gfortran -o f90_SURGE.exe f90_SURGE.f90 f90_SURGE inp_surge_Ha.csv out_surge_Ha.csv f90_SURGE inp_surge_Hc.csv out_surge_Hc.csv f90_SURGE inp_surge_Ta.csv out_surge_Ta.csv f90_SURGE inp_surge_Tc.csv out_surge_Tc.csv gfortran -o f90_DRAW_SURGE.exe f90_DRAW_SURGE.f90 f90_DRAW_SURGE out_surge_Ha.csv fig_surge_Ha.eps f90_DRAW_SURGE out_surge_Hc.csv fig_surge_Hc.eps f90_DRAW_SURGE out_surge_Ta.csv fig_surge_Ta.eps f90_DRAW_SURGE out_surge_Tc.csv fig_surge_Tc.eps
Filename | Description |
---|---|
f90_SURGE.txt | program for Surging analysis for Restricted Orifice Surge Tank |
f90_DRAW_SURGE.txt | program to draw the time history of water surface using gnuplot |
inp_surge_Ha.txt | sample input data (headrace surge tank: load interception) |
inp_surge_Hc.txt | sample input data (headrace surge tank: input interception) |
inp_surge_Ta.txt | sample input data (tailrace surge tank: load interception) |
inp_surge_Tc.txt | sample input data (tailrace surge tank: input interception) |
fig_surge_Ha.png | sample figure (headrace surge tank: load interception) |
fig_surge_Hc.png | sample figure (headrace surge tank: input interception) |
fig_surge_Ta.png | sample figure (tailrace surge tank: load interception) |
fig_surge_Tc.png | sample figure (tailrace surge tank: input interception) |
gfortran -o f90_TUNNEL.exe f90_TUNNEL.f90 f90_TUNNEL bat_HT1.bat fig_eps_HT1.eps 0 8200 550 0 6000 100 100 f90_TUNNEL bat_HT2.bat fig_eps_HT2.eps 0 6100 550 0 5000 100 100 f90_TUNNEL bat_PS1.bat fig_eps_PS1.eps 1 5400 600 300 5000 100 100 f90_TUNNEL bat_PS2.bat fig_eps_PS2.eps 1 3000 500 100 3000 100 100
The format of command line arguments are shown below.
f90_TUNNEL fnameW fnameF ksp DIA Tc Tx W ts tp
f90_TUNNEL | Compiled F90 program |
fnameW | Batch file for execution of GMT |
fnameF | Output image filename (eps) |
ksp | 0: no-steel lining, 1: steel lining |
DIA | Internal diameter of waterway |
Tc | Thickness of concrete lining |
Tx | Additional thickness of invert concrete |
W | Width of invert concrete |
ts | Thickness of shotcrete |
tp | Thickness from design line to pay line |
Filename | Description |
---|---|
f90_TUNNEL.txt | Program to draw waterway tunnel section |
bat_PS1.txt | Batch file for GMT execution by F90 program (for drawing fig_eps_PS1.eps) |
fig_eps_HT1.png | Output image file (1) |
fig_eps_HT2.png | Output image file (2) |
fig_eps_PS1.png | Output image file (3) |
fig_eps_PS2.png | Output image file (4) |
TeX-TUNNEL.pdf | TeX document sample using eps image file |
Meaming of symbols in the drawings are shown below.
Ae | Area for excavation by pay line |
Ce | Area for concrete by design line |
Ls | Length for shotcrete by design line |
ΔCe | Difference of area between pay line and design line |
ΔLs | Difference of length between pay line and design line |
gfortran -o f90_MANNING_CIRC.exe f90_MANNING_CIRC.f90 gfortran -o f90_MANNING_RECT.exe f90_MANNING_RECT.f90 f90_MANNING_CIRC 1.50 0.06649 0.015 > inp_manning_circ.txt f90_MANNING_RECT 3.00 0.00500 0.015 > inp_manning_rect.txt
The format of command line arguments are shown below.
f90_MANNING_CIRC DD ii nn > fnameW f90_MANNING_RECT BB ii nn > fnameW
f90_MANNING_CIRC | Compiled F90 program for circular cross section |
f90_MANNING_RECT | Compiled F90 program for rectangular cross section |
fnameW | Output file name (text file) |
DD | Diameter of circular waterway |
BB | Width of rectarngular waterway |
ii | Gradient of invert |
nn | Manning's roughness coefficient |
Filename | Description |
---|---|
f90_MANNING_CIRC.txt | Program to obtain the H-Q relationship of circular cross section |
f90_MANNING_RECT.txt | Program to obtain the H-Q relationship of rectangular cross section |
bat_manning_circ.txt | Batch file for GMT execution (for circular cross section) |
bat_manning_rect.txt | Batch file for GMT execution (for rectangular cross section) |
fig_manning_circ.png | Output image file (circular cross section) |
fig_manning_rect.png | Output image file (rectangular cross section) |
gfortran -o f90_SFM.exe f90_SFM.f90 f90_SFM dat_sfm1.csv out_test1.csv 3 1 10 f90_SFM dat_sfm2.csv out_test2.csv 3 1 10 f90_SFM dat_sfm3.csv out_test3.csv 4 1 10 f90_SFM dat_sfm4.csv out_test4.csv 2 1 10 f90_SFM dat_sfm5.csv out_test5.csv 2 1 10 f90_SFM dat_sfm6.csv out_test6.csv 8 1 10 call bat_gmt_ctl_qcss call bat_gmt_ctl_sfm
The format of command line arguments are shown below.
f90_SFM fnameR fnameW n1 m md
f90_SFM | Compiled F90 program for storage function method |
fnameR | Input file name (text file) |
fnameW | Output file name (text file) |
n1 | Starting point of separation of base run-off |
m | Value to specify the separation method of run-off (0: horizontal separation [constant value], 1: using sloped line[optimal ending point is searced]) |
md | Number of division of time increment (integer which shall be greater than or equal to one) |
Filename | Description |
---|---|
f90_SFM.txt | F90 program for storage function method |
dat_sfm1.txt | Input data example (1) |
dat_sfm2.txt | Input data example (2) |
dat_sfm3.txt | Input data example (3) |
dat_sfm4.txt | Input data example (4) |
dat_sfm5.txt | Input data example (5) |
dat_sfm6.txt | Input data example (6) |
bat_gmt_ctl_qcss.txt | Batch file for GMT to make q-S relationship (for control) |
bat_gmt_plt_qcss.txt | Batch file for GMT to make q-S relationship (for drawing commands) |
bat_gmt_ctl_sfm.txt | Batch file for GMT to make hydrograph (for control) |
bat_gmt_plt_sfm.txt | Batch file for GMT to make hydrograph (for drawing commands) |
en_TeX_SFM.pdf | Document of theory and examples |
gfortran -o f90_SFMQ.exe f90_SFMQ.f90 f90_SFMQ dat_sfm1Q.csv out_test1Q.csv 10 call bat_gmt_ctl_sfmQ
The format of command line arguments are shown below.
f90_SFMQ fnameR fnameW md
f90_SFMQ | Compiled F90 frogram for estimation of hydrograph |
fnameR | Input file name |
fnameW | Output file name |
md | Number of division of time increment (integer which shall be greater than or equal to one) |
Filename | Description |
---|---|
f90_SFMQ.txt | F90 program for estimation of hydrograph |
dat_sfm6Q.txt | Input data sample |
bat_gmt_ctl_sfmQ.txt | Batch file for GMT to make hydrograph (for control) |
bat_gmt_plt_sfmQ.txt | Batch file for GMT to make hydrograph (for drawing commands) |
fig_SFM6Q.png | Output sample graph |
Method | Stability condition | |
---|---|---|
Runge-Kutta | dt/Tk<=0.45 | Tk>=0.022 sec.(dt=0.01 sec.) |
Linear Acceleration | dt/Tk<=0.55 | Tk>=0.018 sec.(dt=0.01 sec.) |
gfortran -o f90_ARS_RUNGE.exe f90_ARS_RUNGE.f90 f90_ARS_RUNGE dat_acc_TCGH16_EW2.csv dat_spc_TCGH16_EW2.csv f90_ARS_RUNGE dat_acc_TCGH16_NS2.csv dat_spc_TCGH16_NS2.csv f90_ARS_RUNGE dat_acc_TCGH16_UD2.csv dat_spc_TCGH16_UD2.csv
The format of command line arguments are shown below.
f90_ARS_RUNGE fnameR fnameW
f90_ARS_RUNGE | Compiled F90 program |
fnameR | Input file name |
fnameW | Output file name |
Filename | Description |
---|---|
f90_ARS_RUNGE.txt | program for calculating response spectrum by Runge-Kutta method |
dat_acc_TCGH16_EW2.txt | Input data sample (1) |
dat_acc_TCGH16_NS2.txt | Input data sample (2) |
dat_acc_TCGH16_UD2.txt | Input data sample (3) |
dat_spc_TCGH16_EW2.txt | Output data sample (1) |
dat_spc_TCGH16_NS2.txt | Output data sample (2) |
dat_spc_TCGH16_UD2.txt | Output data sample (3) |
en_TeX_RUNGE.pdf | Document |
gfortran -o f90_RCmSD.exe f90_RCmSD.f90 rem iflag hh bb dd_t dd_c As_t As_c MO f90_RCmSD 1 7.5 25 2.5 0.0 3.925 0.0 8013
The format of command line arguments are shown below.
f90_RCmSD iflag hh bb dd_t dd_c As_t As_c MO
f90_RCmSD | Compiled F90 frogram |
iflag | 1: Single reinforcement, 2: Double reinforcements |
hh, bb | Total height and width of RC section |
dd_t, dd_c | Distance between Tensile re-bar and tensile edge, or Compressive re-bar and compressive edge |
As_t, As_c | Section area of Tensile re-bar, or Compressive re-bar |
MO | Moment (value shall be positive) |
gfortran -o f90_RCmntD.exe f90_RCmntD.f90 rem hh bb dd_t dd_c As_t As_c MO AF f90_RCmntD 350 1000 60 60 1570 1570 140000000 160000
The format of command line arguments are shown below.
f90_RCmntD hh bb dd_t dd_c As_t As_c MO AF
f90_RCmntD | Compiled F90 frogram |
hh, bb | Total height and width of RC section |
dd_t, dd_c | Distance between Tensile re-bar and tensile edge, or Compressive re-bar and compressive edge |
As_t, As_c | Section area of Tensile re-bar, or Compressive re-bar |
MO | Moment (value shall be positive) |
AF | Tensile axial force (value shall be positive) |
Filename | Description |
---|---|
f90_RCmSD.txt | F90 program for estimation of stresses against pure bending |
f90_RCmntD.txt | F90 program for estimation of stresses against bending and tensile axial force |
gfortran -o f90_CPT.exe f90_CPT.f90 f90_CPT inp_CPT_comp.csv out_CPT_comp.csv
f90_CPT | Compiled f90 program |
inp_CPT_comp.csv | Input data filename |
out_CPT_comp.csv | Output data filename |
Filename | Description |
---|---|
f90_CPT.txt | f90 program code for stress calculation of RC Circular Pressure Tunnel |
inp_CPT_comp.txt | Example of input data |
out_CPT_comp.txt | Example of output data |
TeX_CPTT.pdf | Document for theory of calculation |
TeX_CPTT_FEM.pdf | Document of study on RC Circular Pressure Tunnel by FEM |
call getarg(1,dummy1) call getarg(2,dummy2) call getarg(3,dummy3) call getarg(4,fnameR) read(dummy1,*) icase read(dummy2,*) Q0 read(dummy3,*) h0 open(11,file=fnameR,status='old') read(11,*) nd do i=1,nd read(11,'()') read(11,*) k,xx(i),zz(i),nas(i),ninp(i) do j=1,nas(i) read(11,*) hh(i,j),area(i,j),wper(i,j),wids(i,j) end do end do close(11)
nd | Number of the section calculated |
k | Section No.(arbitrary) |
xx(i) | Horizontal distance from starting point of calculation |
zz(i) | Elevation of river bed |
nas(i) | Number of input for the relationship between depth and section area |
ninp(i) | Roughness coefficient |
hh(i,j) | Water depth in the perpendicular direction to the river bed |
area(i,j) | Section area of flow at the specified water depth |
wper(i,j) | Wetted perimeter at the specified water depth |
wids(i,j) | Width of Water surface at the specified water depth |
The sequence of the section shall be from starting point of calculation to end point. In this case, the sequence of section shall be from downstream to upstream because of Subcritical flow.
gfortran -o f90_NUF.exe f90_NUF.f90 f90_NUF 10 430.92 1.958 inp_open.txt > outQ0430.txt
f90_NUF | f90 program for execution compiled |
10 | icase=10: Subcritical flow, icase=20: Supercritical flow |
430.92 | Q0 : Discharge at starting point of calculation |
1.9582 | h0 : Water depth at starting point of calculation |
inp_open.txt | fnameR : Input data file name |
outQ0430.txt | Output data file name |
x1 | Horizontal distance from starting point of calculation |
Q1 | Discharge |
a1 | Section area of flow |
t1 | Width of water surface |
h1 | Water depth in the perpendicular direction to the river bed |
z1 | Elevetion of river bed |
h1+z1 | Elevation of water surface |
v1 | Mean velocity of flow |
E1 | Total head of energy (including the dynamic head) |
Fr | Froude number |
hc | Critical depth in the perpendicular direction to the river bed |
it | Count of iteration for convergence |
Filename | Description |
---|---|
f90_NUF.txt | Source code of the program for non unuform flow analysis |
inp_open.txt | Sample of input data |
outQ0430.txt | Sample of output data |
TeX_nuf.pdf | Sample of useage of this program |
gfortran -o f90_floodr.exe f90_floodr.f90 f90_floodr inp_kusan_hv.txt inp_kusan_pmf_0.txt > test0.txt f90_floodr inp_kusan_hv.txt inp_kusan_pmf_1.txt > test1.txt
f90_floodr fnameR1 gnameR2 > fnameW
f90_floodr | Compiled program for execution |
fnameR1 | Input data (H-V curve of reservoir) |
fnameR2 | Input data (Inflow data) |
fnameW | Output data |
vcoef rh(1) rv(1) rh(2) rv(2) rh(3) rv(3) ... ...
vcoef | Coefficient multiplied to the volume |
rh(i) | Water level |
rv(i) | Cumulative volume / vcoef |
ELini outlet ti(1) q_in(1) ti(2) q_in(2) ti(3) q_in(3) ... ...
ELini | Initial water level (EL.m) |
outlet | Discharge from outlet (constant) (m3/s) |
ti(i) | time (hour) |
q_in(i) | Inflow (m3/s) / vcoef |
i | Step no. |
iUD | Index for up-down of reservoir water level(1: up, -1: down) |
ti | Time (hour) |
EL | reservoir water level (EL.m) |
EL-elv | error of water level (m) |
VOL | Cumulative volume of reservoir (m3) |
q_in | Inflow (m3/s) |
q_out | Outflow (m3/s) |
File name | Description |
---|---|
f90_floodr.txt | Source code of program |
inp_kusan_hv.txt | Sample input data (H-V curve of reservoir) |
inp_kusan_pmf_0.txt | Sample input data (1) (Inflow data) |
inp_kusan_pmf_1.txt | Sample input data (2) (Inflow data) |
a_gmt.txt | GMT script for drawing |
awk_klegend.txt | awk script to draw a legend |
fig_test0.png | Sample drawing (1) |
fig_test1.png | Sample drawing (2) |