Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › Fortran... how different is it compared to java or c++?
New Posts  All Forums:Forum Nav:

Fortran... how different is it compared to java or c++? - Page 2

post #11 of 13
Quote:
Originally Posted by DuckieHo;13528093 
FORTRAN is still in limited use in the science community where the coding is basically calculation only.

Haha yep, I figured that out after a brief visit to Wikipedia.

In school freshmen started out with Fortran 77 and inputting their programs onto a beastly old Honeywell mainframe. Fortunately we had monochrome terminals and didn't have to use punch cards!

lachen.gif

After that, it was basically forget about Fortran forever.
Underground
(14 items)
 
  
CPUMotherboardGraphicsRAM
Core i7 920 C0 ASUS P6T6 WS Revolution GTX 460 TR3X6G1600C8D 
Hard DriveOptical DriveCoolingOS
WD1001FALS SAMSUNG SH-S223F 22X DVD MULTI Corsair H50 Fedora 16 KDE x86_64 
MonitorKeyboardPowerCase
HP w19b Microsoft Comfort Curve Corsair CX600 Thermaltake Armor VA8003BWS 
MouseMouse Pad
Razer DeathAdder Black 
  hide details  
Reply
Underground
(14 items)
 
  
CPUMotherboardGraphicsRAM
Core i7 920 C0 ASUS P6T6 WS Revolution GTX 460 TR3X6G1600C8D 
Hard DriveOptical DriveCoolingOS
WD1001FALS SAMSUNG SH-S223F 22X DVD MULTI Corsair H50 Fedora 16 KDE x86_64 
MonitorKeyboardPowerCase
HP w19b Microsoft Comfort Curve Corsair CX600 Thermaltake Armor VA8003BWS 
MouseMouse Pad
Razer DeathAdder Black 
  hide details  
Reply
post #12 of 13
Down the hall from me lives Fortran and COBAL....think there's still some ADA programs downstairs.
Nightshade
(20 items)
 
  
CPUMotherboardGraphicsGraphics
i7-4930k Asus Rampage IV Extreme EVGA - Titan-X Superclocked EVGA - Titan-X 
RAMHard DriveHard DriveHard Drive
64 GB Corsair Vengance DDR3 OCZ Agility 3 Intel 540 240GB 7200 RPM Platter Drive 
Hard DriveCoolingOSMonitor
1TB Mushkin SSD Watercooled Windows 10 Pro x64 ASUS ROG Swift 
KeyboardPowerCaseMouse
Razer Black Widow Chroma Corsair RM1000 Corsair 900D Razer Deathadder Chroma 
Mouse PadAudioOther
Steelseries Soundblaster Z Speakers: Logitech z5500 
  hide details  
Reply
Nightshade
(20 items)
 
  
CPUMotherboardGraphicsGraphics
i7-4930k Asus Rampage IV Extreme EVGA - Titan-X Superclocked EVGA - Titan-X 
RAMHard DriveHard DriveHard Drive
64 GB Corsair Vengance DDR3 OCZ Agility 3 Intel 540 240GB 7200 RPM Platter Drive 
Hard DriveCoolingOSMonitor
1TB Mushkin SSD Watercooled Windows 10 Pro x64 ASUS ROG Swift 
KeyboardPowerCaseMouse
Razer Black Widow Chroma Corsair RM1000 Corsair 900D Razer Deathadder Chroma 
Mouse PadAudioOther
Steelseries Soundblaster Z Speakers: Logitech z5500 
  hide details  
Reply
post #13 of 13
Never have used FORTRAN, but C++ seems more readable to me. Bear in mind C++ is the language I use primarily.
Code:
//  This illustrates how a Fortran routine and function may be   
//  called from a main program in C++   

#include <iostream.h>   
extern "C"   
{       
    void __stdcall FR1(int*,int *);
     int __stdcall FF1(int *);   
}  

int main()
{       
    int n=10,nSq,nCube;
    FR1(&n,&nSq);
    cout << "The square is:" << nSq << endl;       
    nCube=FF1(&n);
    cout << "The Cube is:" << nCube << endl;
    return 0;   
}    

//The Fortran File:

         SUBROUTINE FR1(N,M)
   C     COMPUTES THE SQUARE OF N, RETURNS IN M
              M=N*N
         RETURN
         END
   C
         INTEGER FUNCTION FF1(N)
   C     COMPUTES THE CUBE OF N
         FF1=N*N*N
         RETURN
         END

Edited by lordikon - 5/17/11 at 1:21pm
Foldatron
(17 items)
 
Mat
(10 items)
 
Work iMac
(9 items)
 
CPUMotherboardGraphicsGraphics
i7 950 EVGA x58 3-way SLI EVGA GTX 660ti GTX 275 
RAMHard DriveHard DriveHard Drive
3x2GB Corsair Dominator DDR3-1600 80GB Intel X25-M SSD 2TB WD Black 150GB WD Raptor 
Hard DriveOSMonitorKeyboard
2x 150GB WD V-raptor in RAID0 Win7 Home 64-bit OEM 55" LED 120hz 1080p Vizio MS Natural Ergonomic Keyboard 4000 
PowerCase
750W PC P&C Silencer CoolerMaster 690 
CPUGraphicsRAMHard Drive
Intel Core i5 2500S AMD 6770M 8GB (2x4GB) at 1333Mhz 1TB, 7200 rpm 
Optical DriveOSMonitorKeyboard
LG 8X Dual-Layer "SuperDrive" OS X Lion 27" iMac screen Mac wireless keyboard 
Mouse
Mac wireless mouse 
CPUGraphicsRAMHard Drive
i7-2600K AMD 6970M 1GB 16GB PC3-10600 DDR3 1TB 7200rpm 
Hard DriveOptical DriveOSMonitor
256GB SSD 8x DL "SuperDrive" OS X 10.7 Lion 27" 2560x1440 iMac display 
Monitor
27" Apple thunderbolt display 
  hide details  
Reply
Foldatron
(17 items)
 
Mat
(10 items)
 
Work iMac
(9 items)
 
CPUMotherboardGraphicsGraphics
i7 950 EVGA x58 3-way SLI EVGA GTX 660ti GTX 275 
RAMHard DriveHard DriveHard Drive
3x2GB Corsair Dominator DDR3-1600 80GB Intel X25-M SSD 2TB WD Black 150GB WD Raptor 
Hard DriveOSMonitorKeyboard
2x 150GB WD V-raptor in RAID0 Win7 Home 64-bit OEM 55" LED 120hz 1080p Vizio MS Natural Ergonomic Keyboard 4000 
PowerCase
750W PC P&C Silencer CoolerMaster 690 
CPUGraphicsRAMHard Drive
Intel Core i5 2500S AMD 6770M 8GB (2x4GB) at 1333Mhz 1TB, 7200 rpm 
Optical DriveOSMonitorKeyboard
LG 8X Dual-Layer "SuperDrive" OS X Lion 27" iMac screen Mac wireless keyboard 
Mouse
Mac wireless mouse 
CPUGraphicsRAMHard Drive
i7-2600K AMD 6970M 1GB 16GB PC3-10600 DDR3 1TB 7200rpm 
Hard DriveOptical DriveOSMonitor
256GB SSD 8x DL "SuperDrive" OS X 10.7 Lion 27" 2560x1440 iMac display 
Monitor
27" Apple thunderbolt display 
  hide details  
Reply
New Posts  All Forums:Forum Nav:
  Return Home
  Back to Forum: Coding and Programming
Overclock.net › Forums › Software, Programming and Coding › Coding and Programming › Fortran... how different is it compared to java or c++?