- Marquer comme nouveau
- Marquer
- S'abonner
- Sourdine
- S'abonner au fil RSS
- Surligner
- Imprimer
- Signaler un contenu inapproprié
I am using ivf 2018 u3 on a Win 10 machine and I've run into an odd behavior that I cannot fix. First I show you the output on the console:
Name Var. xbar N 1 11.5406 1/N 2 0.1039 1/N^2 3 0.0129 Y 4 67.8702 Name Var. Std.Dev. N 1 4.7798 1/N 2 0.0476 1/N^2 3 0.0118 Y 4 15.7757
All the arithmetic is correct but the format is messy. I was using a format statement with the fields: "A, T11, i2, T15, f15.4" and then I tried something a little different:but I get exactly the same results. Here is the code:
do i = 1, nVars mLine = ' ' mLine(1:9) = Names(i)(1:9) write(mLine(11:12),'(i2)') i write(mLine(15:30),'(f15.4)') xb(i) write(6,'(a30)') mLine(1:30) end do
I am using a Courier font. Does anyone have a suggestion? I am at a loss.
Thanks, Brooks
- Balises:
- Intel® Fortran Compiler
- Marquer comme nouveau
- Marquer
- S'abonner
- Sourdine
- S'abonner au fil RSS
- Surligner
- Imprimer
- Signaler un contenu inapproprié
Try putting
write(6,*) ichar(transfer(Names(i)(1:9),['A']))
in the loop so we can see if there are any hidden characters (like HT) in the Names strings.
Lien copié
- Marquer comme nouveau
- Marquer
- S'abonner
- Sourdine
- S'abonner au fil RSS
- Surligner
- Imprimer
- Signaler un contenu inapproprié
Try putting
write(6,*) ichar(transfer(Names(i)(1:9),['A']))
in the loop so we can see if there are any hidden characters (like HT) in the Names strings.
- Marquer comme nouveau
- Marquer
- S'abonner
- Sourdine
- S'abonner au fil RSS
- Surligner
- Imprimer
- Signaler un contenu inapproprié
What is the length of the `Names` object? Is its LEN more than 9?
- Marquer comme nouveau
- Marquer
- S'abonner
- Sourdine
- S'abonner au fil RSS
- Surligner
- Imprimer
- Signaler un contenu inapproprié
Hello
Why not ?
write(6,'(A9,2x,i2,2x,F15.4)')Names(i),i,xb(i)
- Marquer comme nouveau
- Marquer
- S'abonner
- Sourdine
- S'abonner au fil RSS
- Surligner
- Imprimer
- Signaler un contenu inapproprié
Thanks, the problem was tab characters within Names(*), which I had read from a text file.
Brooks

- S'abonner au fil RSS
- Marquer le sujet comme nouveau
- Marquer le sujet comme lu
- Placer ce Sujet en tête de liste pour l'utilisateur actuel
- Marquer
- S'abonner
- Page imprimable