LinkBack Thread Tools Search this Thread Display Modes
Prev Previous Post   Next Post Next
  #4   Report Post  
Old May 7th 04, 06:28 PM
Tom Bruhns
 
Posts: n/a
Default

I'm not sure what calcs you need to run, but wouldn't it be trivial to
do a test of Matlab's speed with respect to the sorts of things you
need to do? It's one of the very nice things about an interpreted
matrix language. I use Scilab (freeware), and just ran a little test:
create a=rand(200,200), b=rand(200,200), c=a*b, ainv=inv(a), and then
evaluate ainv*c-b, to make sure it comes out close to zero. It did,
and the whole thing was fast enough that I couldn't time it accurately
till I put it in a loop to repeat ten times. It's about 1.4 seconds
per iteration. Guess I could have let it time itself, too. That's on
a 700MHz Pentium machine. (Considering the work I put into inverting
matrices in my linear algebra class years ago, the speed with which it
can invert a large matrix puts a wry smile on my face.) Scilab, as
Matlab, can compile functions, but if your math is very compact
because of the matrix notation, it may not really matter much; most of
the time is spent doing the matrix math anyway. And if the matrix
notation lets you do things in a way that's more readable, that's a
huge plus, and also consider the time you'll save programming (unless
you already have good matrix libraries available, I suppose).

(By the way, last time I checked, 200*200 = 40000, not 4000. ;-)

Cheers,
Tom



"Arun S V" wrote in message ...
Hello all the FDTD experts over there ,

I am starting out on my class project which requires me to write
a 2D FDTD code.I am thinking of doing it in Matlab or C.Matlab would offer
good user friendliness but I have heard that Matlab being an interpreted
language is quite slow when it comes to loops.My requirement is about 4000
cells utmost ( 200 x 200 ) and time step of the order of 1 Pico second.Will
Matlab be very slow that I should consider coding in C or will Matlab do
okay with respect to the execution time.



-Warm regards
--Arun S V

 
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

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



All times are GMT +1. The time now is 10:15 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 RadioBanter.
The comments are property of their posters.
 

About Us

"It's about Radio"

 

Copyright © 2017