由买买提看人间百态

topics

全部话题 - 话题: gfortran
首页 上页 1 2 (共2页)
B**F
发帖数: 38
1
来自主题: Programming版 - C中的精度问题
太初级了只好披马甲来问。
如下程序,如何把example文件中的数字位数一位不少地读入?
试了lf不管用:
0, -0.999714 0.000734634
1, -0.998492 0.00170939
2, -0.996295 0.00268393
多谢指教了!(以下代码中“n"显示不出来)
gfortran, Mac OS X 10.6.7
#include
void main(void)
{
double Z1[3], Z2[3];
int i;
FILE *input= fopen ("example", "r");
for (i=0; i<3; ++i) {
fscanf(input, "%lf %lfn", &Z1[i], &Z2[i]);
printf("%i, %g %gn", i, Z1[i], Z2[i]);}
fclose(input);
return 0;
}
文件"example"内容:
-0.99971372677344128 ... 阅读全帖
t*****n
发帖数: 4908
2
来自主题: Programming版 - Windows 7 下的 fortran compiler
gfortran
可以配合mingw使用。请google之。
S**I
发帖数: 15689
3
来自主题: Programming版 - convert Fortune code to Matlab
gfortran

get
t*****n
发帖数: 4908
4
gfortran有windows版
d****n
发帖数: 1241
5
来自主题: Programming版 - C++ 11问题:emplace_back()
新东西,没有太多冗余在里边。
GCC发展了这么多年,有不少东西都在一定程度上阻碍了他的发展,
比如说,GCC支持的后端比LLVM多,前端还有gfortran一样的东西,
支持的东西多了,塞进代码里的包袱也就多。。。整体改动起来也
就更难了
D***n
发帖数: 6804
6
来自主题: Programming版 - 请不要盲目崇拜FP语言
MLlib uses the linear algebra package Breeze, which depends on netlib-java,
and jblas. netlib-java and jblas depend on native Fortran routines. You need
to install the gfortran runtime library if it is not already present on
your nodes. MLlib will throw a linking error if it cannot detect these
libraries automatically.
LOL
Spark用的是你仇恨的Fortran做后台计算,没libgfortain都运行不了。
你还扯什么蛋?你现在都没安装过SPARK么。
D***n
发帖数: 6804
7
来自主题: Programming版 - 请不要盲目崇拜FP语言
愚蠢之至的思路,除了显示你对计算一无所知还能说明啥?
你知道netlib,Lapack, Atlas是什么江湖地位么?你知道这些库花了多少人多少精力
和银子么?还短期无法完成代码,哈哈哈!
Scipy里面也用同样的库,所以你拿SPARK去比,只能比出同样的速度来。
Before building, you will also need to install packages that NumPy and SciPy
depend on
BLAS and LAPACK libraries (optional but strongly recommended for NumPy,
required for SciPy): typically ATLAS + LAPACK, or MKL, or ACML
C and Fortran compilers (typically gcc and gfortran).
z****e
发帖数: 54598
8
来自主题: Programming版 - 请不要盲目崇拜FP语言
lol
我说的是python吗?
你到底安装过scipy没有?
scipy在python下安装就一句话?
哈哈,你google下,看多少人在说安装scipy有多痛苦
你根本就没做过
告诉你吧
scipy要先安装xcode,其次再调整一个什么参数,忘了,ui的好像
然后安装gfortran,然后重新编译,一堆warning
因为fotran的pkg不能跨平台,需要重新编译
你就一骗子,根本没做过
numpy比较容易,这个我信,scipy比较麻烦
matplotlib就更苦逼了,上次我需要修改源代码加了一个声明才能调用
鬼知道那句话是啥意思
f*********e
发帖数: 487
9
来自主题: Programming版 - is g77 abandoned?
want to install GNU g77, but seems the Internet does not have it anymore.
Some says it is obsolete. It is replaced by gfortran or fort77
w*x
发帖数: 518
10
来自主题: Programming版 - is g77 abandoned?
I think it has been obsolete for a while. Is there a specific reason to not
to use gfortran?
f*********e
发帖数: 487
11
来自主题: Programming版 - is g77 abandoned?
I see. No, I am open to any of them. Just have been used to g77. Later I
installed both fort77 and gfortran, and both work fine.

not
l********r
发帖数: 175
12
【 以下文字转载自 Linux 讨论区 】
发信人: lilyflower (smile), 信区: Linux
标 题: what kind of language this is and how to change it?
发信站: BBS 未名空间站 (Fri Aug 8 11:58:26 2008)
In my f90 source code files, it has following lines:
#ifdef SYNC
call mpi_barrier(mpi_comm_world,ierror)
#endif
what kind of languages that used? when using gfortran compiler to compile it
, I got warning message as: Illegal preprocessor directive.
I tried to correct it. How to change the source code or makefile a little
bit so that
y****a
发帖数: 109
13
f90 is the generic name for a Fortran 90/95 compiler. Commonly available
Fortran 90/95 compilers are Gfortran, G95.
O******e
发帖数: 734
14
Does the gcc include gfortran?
c**********e
发帖数: 27
15
来自主题: Windows版 - Run Fortran on Windows XP
I have a problem with redirection '<'
I have downloaded Gfortran compiler, it works well. I tried both Cygwin and
Windows powershell, both of them do not support <. Anyone know other good
console for running Fortran code.
Thanks!
D********g
发帖数: 533
16
来自主题: ChemEng版 - 请教有关fortran
Free compiler:
1. GNU gFortran http://gcc.gnu.org/fortran/
If you have computer facilities in your dept, they should be there. just g77
to invoke that.
2. Intel Fortran Compiler: http://www.intel.com/cd/software/products/asmo-na/eng/282048.htm
Free for non-comercial Use.
Good for Win.
3. Compaq Visual FORTRAN
Like Visual Studio, but it's not free. And not recommend to use.

code
p**i
发帖数: 100
17
来自主题: Computation版 - 请教: 关于Fortran编译器
GCC 现在就有fortran,gfortran

在 GoHokies (GoHokies) 的大作中提到: 】
Fort
b**n
发帖数: 289
18
来自主题: Computation版 - Free Fortran compiler for Linux (转载)
【 以下文字转载自 Linux 讨论区 】
发信人: bsun (下次再起), 信区: Linux
标 题: Free Fortran compiler for Linux
发信站: BBS 未名空间站 (Sun Nov 12 14:47:26 2006)
Has anyone used GNU fortran 90/95 compiler before? How is that?
Btw, it's gfortran, right?
Thanks very much.
l******n
发帖数: 9344
19
I am saying ifort is slow from my own experience, and it depends on my
machine of course. For compiling the same program, pfg90 and mpif90 is much
faster than ifort for me.
mixing compilors is doable, but you need to figure out the settings and all
the flags. Different compiler has different default setting, so reading the
whole manual is must. There also might be something which has not a
counterpart in others, this is very bad.

gfortran,
have
O******e
发帖数: 734
20
来自主题: Computation版 - Fortran应该装哪个compiler好?
Linux plus Intel ifort noncommercial license (no fee).
Intel's noncommercial ifort is not available for any
Windows platform.
Or try GCC's gfortran, but it is still buggy.
Or go to fortran.com and look through the list of
compilers, see what suits you.
l***s
发帖数: 1405
21
gfortran?
t****b
发帖数: 47
22
来自主题: Computation版 - 请教Unix中怎么编译Fortun文件
写一个fortran的程序,起名字,例如aaa.f
make aaa
即可,如果存在默认的fortran编译器,就能生成可执行文件aaa,可使用./aaa 的方式
执行只
fortran编译器通常可能是
f77、g77、gfortran、pgf77、pgf95、ifort等
m*******1
发帖数: 58
23
来自主题: Computation版 - Gfortran library
1. 矩阵计算, 你可以用其它的函数库, 比如: BLAS, gotoBLAS, LAPACK, etc.
2. For non-commercial use, 你可以试试 Intel Fortran for Linux 和 MKL库, non-
commercial version is free. 生成的代码计算效率非常高.
x*****u
发帖数: 3419
24
来自主题: Computation版 - Gfortran library
how about this one:
http://www.gnu.org/software/gsl/
m*******1
发帖数: 58
25
来自主题: Computation版 - Gfortran library
可以看看各种函数库的比较:
http://wenku.baidu.com/view/828a7aa1284ac850ad024248.html
我比较喜欢用GotoBLAS.
k****5
发帖数: 546
26
来自主题: Computation版 - Gfortran library

thanks, very useful document
t*****n
发帖数: 4908
27
来自主题: Computation版 - Gfortran library
猴子说的没错,同道中人。
c*m
发帖数: 1114
28
来自主题: Computation版 - 懂fortran的帮忙看一下
Intel Fortran 和gfortran Result 都是:
4.999999999999999E+017
l*******G
发帖数: 1191
29
来自主题: Computation版 - fortran90 奇怪的格式问题
对于自己定义的数据(结构)的成员打印格式居然出问题。有兴趣的看一下为何主程序
最后两行打印结果不一样?gfortran and ifort give same results on linux.
=====save to test.f90, and then "ifort test.f90" and then "./a.out" to run=====
module numz
integer, parameter:: b8 = selected_real_kind(14)
integer,allocatable :: a_gene(:),many_genes(:,:)
end module
module galapagos
use numz
... 阅读全帖
l*******G
发帖数: 1191
30
来自主题: Computation版 - fortran90 奇怪的格式问题
对于自己定义的数据(结构)的成员打印格式居然出问题。有兴趣的看一下为何主程序
最后两行打印结果不一样?gfortran and ifort give same results on linux.
=====save to test.f90, and then "ifort test.f90" and then "./a.out" to run=====
module numz
integer, parameter:: b8 = selected_real_kind(14)
integer,allocatable :: a_gene(:),many_genes(:,:)
end module
module galapagos
use numz
... 阅读全帖
R********s
发帖数: 182
31
我有fortran 的code YYY.f90 如下:
PROGRAM MAIN
!
implicit none
INTEGER lambda(2),lim
integer df(2),ifault
REAL q,nc(2),sigma,acc,trace(7),res
nc = (/0,0/)
lambda=(/0.5,0.5/)
df = (/1,1/)
q = 10
lim = 10000
sigma = 0
acc = 0.0001
res = 0
call compute(lambda,nc,df,2,sigma,q,lim,acc,trace,ifault,res)
END program MAIN
XXX.cpp的code 如下:
#define UseDouble 0 /* all floating point double */
#include
#include 阅读全帖
m******s
发帖数: 612
32
Compiler doesn't support this option. find another one or do the swap by
yourself, not hard. many sample code
z****u
发帖数: 9
33
来自主题: ME版 - fortran compiler
mingw + gfortran
g****g
发帖数: 1828
34
来自主题: Physics版 - madgraph安装不上
made a link but still doesn't work.
lrwxrwxrwx 2 root root 12 2009-11-08 13:03 g77 -> gfortran-4.4
Running make for MadGraphII
make[1]: Entering directory `/home/weigang/Downloads/MG_ME_V4.4.32/
MadGraphII'
g77 -O -i4 -ffixed-line-length-132 -c driver.f
f951: error: unrecognized command line option "-i4"
make[1]: *** [driver.o] Error 1
make[1]: Leaving directory `/home/weigang/Downloads/MG_ME_V4.4.32/MadGraphII'
make: *** [mg2] Error 2
q********g
发帖数: 10694
35
来自主题: _Molecular_Simulation版 - DL-POLY4.01 CUDA并行安装经验
Core-Shell模型使用dl-poly是最方便了。因此只好用了。
1.确定你的机器安装mpich2,我装的版本是1.2.1p1。compile的时候确定使用--enable
-f90 --enable-cxx FC=(你的fortran编译器)
2.安装fftw,我使用的2.1.5,不确定fftw3是否支持。编译时保证有--enable-mpi --
enable-fortran --enable-threads F77=(你的fortran编译器)。默认安装了双精度之
后。再安装单精度--enable-float --enable-type-prefix。
3. 安装:显卡驱动程序,cudatoolkit与SDK。我使用版本是3.1。root权限下sh ./
cudatoolkit.***.run安装即可。
把以上bin与lib或lib64设置PATH与LD_LIBRARY_PATH环境变量。(版本不一定是越新越
好,主要是看你用的软件写的时候用了什么版本。这里用了老版本主要是和我正在使用
的LAMMPS保持一致。)
把source/CUDA目录下的Makefile_CUDA复制... 阅读全帖
首页 上页 1 2 (共2页)