Y
Y
Yelpi2021-04-08 10:04:37
Fortran
Yelpi, 2021-04-08 10:04:37

What does the dot after a digit mean in Fortran?

For example, I have a line like this
X=AL*(RM*AM+SQRT(AM*AM+(1.-RM*RM)*AN*AN))/(AM*AM+AN*AN)
What does 1 mean in it .?
Or this line. The same.
A = SQRT(1.-DCP*DCP)
Please tell me

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
VitalyChaikin, 2021-04-08
@VitalyChaikin

A REAL type literal consists of one or more digits and a decimal point
In simple terms, this is equivalent to 1.0 (of type REAL)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question