CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > General Forums > Main CFD Forum

How to calculate computaional time

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   July 21, 2008, 13:09
Default How to calculate computaional time
  #1
student
Guest
 
Posts: n/a
Dear Sir,

I am running c++ program in linux and to calulate computational time . I have given "time ./a.out" which gives elapsed time say suppose 1 hr 30 min with 75% CPU which is not appropriate commutaional time . How to find to correct computational time . Is there any other command.
  Reply With Quote

Old   July 24, 2008, 00:17
Default Re: How to calculate computaional time
  #2
Ramesh.K
Guest
 
Posts: n/a
use clock function

int timer clock(); ur code here ................. timer = clock() ; cout<<(timer/(float)1000000) <<endl;

gives the time taken for ur code in secs

  Reply With Quote

Old   July 24, 2008, 01:40
Default Re: How to calculate computaional time
  #3
student
Guest
 
Posts: n/a
Dear Ramesh ,Thank you very much. I will try.
  Reply With Quote

Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Multiple floating objects CKH OpenFOAM Running, Solving & CFD 14 February 20, 2019 09:08
How to write k and epsilon before the abnormal end xiuying OpenFOAM Running, Solving & CFD 8 August 27, 2013 15:33
How to calculate simulation time? Yur Main CFD Forum 7 August 25, 2011 16:53
how to calculate the averaged mass flow along a line over time ? iampolaris OpenFOAM Post-Processing 0 March 10, 2011 22:03
calculate time scale for mesh deformation analysis wilsonbrad CFX 1 October 23, 2009 06:44


All times are GMT -4. The time now is 16:58.