CosmoMC (v Oct 2011): cmbtypes.f90 compilation error

Use of Cobaya. camb, CLASS, cosmomc, compilers, etc.
Post Reply
Ali Vanderveld
Posts: 3
Joined: August 29 2007
Affiliation: JPL / Caltech

CosmoMC (v Oct 2011): cmbtypes.f90 compilation error

Post by Ali Vanderveld » December 14 2011

Hi, I'm trying to get the latest version of CosmoMC to run out of the box (without using WMAP or any additional datasets), but I'm having difficulty compiling. The problem seems to be in compiling cmbtypes.f90, leading to the following errors:
ifort -DMATRIX_SINGLE -w -O3 -mdynamic-no-pic -framework Accelerate -openmp -I../camb -DNOWMAP -c cmbtypes.f90
cmbtypes.f90(34): error #6418: This name has already been assigned a data type. [NUM_MATTER_POWER]
integer, parameter :: num_matter_power = 74 !number of points computed in matter power spectrum
------------------------^
cmbtypes.f90(35): error #6418: This name has already been assigned a data type. [MATTER_POWER_MINKH]
real, parameter :: matter_power_minkh = 0.999e-4 !1e-4 !minimum value of k/h to store
------------------------^
cmbtypes.f90(36): error #6418: This name has already been assigned a data type. [MATTER_POWER_DLNKH]
real, parameter :: matter_power_dlnkh = 0.143911568 !log spacing in k/h
------------------------^
cmbtypes.f90(37): error #6418: This name has already been assigned a data type. [MATTER_POWER_MAXZ]
real, parameter :: matter_power_maxz = 0. !6.0
------------------------^
cmbtypes.f90(38): error #6418: This name has already been assigned a data type. [MATTER_POWER_LNZSTEPS]
integer, parameter :: matter_power_lnzsteps = 1 !20
------------------------^
compilation aborted for cmbtypes.f90 (code 1)
make: *** [cmbtypes.o] Error 1
I'm using the default settings for everything possible (aside from pointing to the correct LAPACK location). Any ideas as to what I'm doing wrong? Thanks in advance.

Antony Lewis
Posts: 1947
Joined: September 23 2004
Affiliation: University of Sussex
Contact:

Re: CosmoMC (v Oct 2011): cmbtypes.f90 compilation error

Post by Antony Lewis » December 15 2011

I think these aren't the default ifort parameters. In particular you need -fpp to preprocess the files.

Ali Vanderveld
Posts: 3
Joined: August 29 2007
Affiliation: JPL / Caltech

CosmoMC (v Oct 2011): cmbtypes.f90 compilation error

Post by Ali Vanderveld » December 15 2011

This has solved the problem. Thanks again!

Post Reply