Contact US

Log In

Come Join Us!

Are you an
Engineering professional?
Join Eng-Tips Forums!
  • Talk With Other Members
  • Be Notified Of Responses
    To Your Posts
  • Keyword Search
  • One-Click Access To Your
    Favorite Forums
  • Automated Signatures
    On Your Posts
  • Best Of All, It's Free!

*Eng-Tips's functionality depends on members receiving e-mail. By joining you are opting in to receive e-mail.

Posting Guidelines

Promoting, selling, recruiting, coursework and thesis posting is forbidden.

Students Click Here

Import binary file to Mathcad 14 - size limit?

Import binary file to Mathcad 14 - size limit?

Import binary file to Mathcad 14 - size limit?

I have created a Mathcad 14 worksheet which reads and processes a large binary data file - specifically, a tile of NASA SRTM terrain elevation data. The worksheet works fine using the generally available 3 arc-second resolution files, which are typically about 1 - 2 MB each, with over 1,000,000 records in each file. (Each file has one integer entry for the elevation data of each point on a 1,201 x 1,201 grid, for 1,442,401 integers in total.)

I would like to use the same worksheet to process some 1 arc-second data files, which have approximately 9 times the number of records, and 9 times the file size (approx. 25 MB each).

When I try to point the "Import Data Wizard" at one of the larger files, it first seems to work fine, but then it loses the data from the imported data file, and the worksheet stops working, as it has no data in the main data array.

I suspect this is an issue with the file size exceeding some limit of Mathcad for handling large binary files, and / or exceeding memory limits.

Does anyone know what are the effective limits for handling large binary files in Mathcad 14? I couldn't find anything in the documentation.

Thanks for any help!

RE: Import binary file to Mathcad 14 - size limit?

I received an answer to my question on the PlanetPTC Mathcad Community site http://communities.ptc.com/message/155327, but I thought I would post the answer here as well, in case it helps anyone else with a similar problem:

Doing a bit of experimentation, I find that the biggest vector I can create from scratch has 8,388,608 elements (from 0 to 8,388,607); that is, 2^24 elements in total.

Mathcad 14 on-line help doesn't mention any absolute hard-wired maximum element limit:
The array size limit depends on the memory available on your system. Approximately 8 bytes of memory are needed per array element. For most systems, the array limit is at least 1 million elements. Note that the maximum allocatable memory in a 32 bit system is 4 Gb, which has to hold all open applications, your operating system, and whatever memory is consumed by your calculations.
but on my system (Mathcad 14 M020, Windows XP SP3, 2 GB RAM) it seems to be a hard upper limit of 8,388,608 elements.  
Also, it seems that Mathcad is not handling dynamic reallocation of memory very well - if I try to create two such vectors, it throws an error of "not enough memory" for the second vector; but when I delete the offending statement which attempted to create the second vector, the first vector is also corrupted due to "not enough memory".
At least I now know where my problem lies - I'll have to see if I can manually parse the terrain file into smaller chunks of less than 8,000,000 elements.

RE: Import binary file to Mathcad 14 - size limit?


Trouble is, it's a standard configuration company computer, and you can probably guess how easy it is to get these sort of "special" deals through the IT department!

My problem is - 4 GB RAM _MIGHT_ get me to 16 million elements, but I don't actually understand why 2 GB _WON'T_ get me there. Task Manager indicates I still have quite a bit of free RAM, and after all, 8 million, 16 million - we are only talking about about a few MB of required RAM, out of 2 GB total RAM.

Red Flag This Post

Please let us know here why this post is inappropriate. Reasons such as off-topic, duplicates, flames, illegal, vulgar, or students posting their homework.

Red Flag Submitted

Thank you for helping keep Eng-Tips Forums free from inappropriate posts.
The Eng-Tips staff will check this out and take appropriate action.

Reply To This Thread

Posting in the Eng-Tips forums is a member-only feature.

Click Here to join Eng-Tips and talk with other members! Already a Member? Login


Close Box

Join Eng-Tips® Today!

Join your peers on the Internet's largest technical engineering professional community.
It's easy to join and it's free.

Here's Why Members Love Eng-Tips Forums:

Register now while it's still free!

Already a member? Close this window and log in.

Join Us             Close