×
INTELLIGENT WORK FORUMS
FOR ENGINEERING PROFESSIONALS

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

Generating reports in Word from MathCad calculations
4

Generating reports in Word from MathCad calculations

Generating reports in Word from MathCad calculations

(OP)
Good morning Gentlemen,

I don't frequent this forum much, and I did a quick search but did not find much that related to my question. I use MathCad 11 for completing Seismic Analysis in accordance with the ASME BP&V Code. I have created a template that I input a about a dozen variables into and it will run through about 50-60 equations for me.

I then transpose the results of the MathCad calculations into a Word document that serves as my report. I use Word because it provides a clean mixture of text and equations without having to see what MathCad does (the equation definition and then the equation solution side by side)

My question is: Is there a way that I can export only my results into defined points of a Word document? Like with Excel and Word, you can link a spreadsheet to a document and as you change the spreadsheet it will update the Word Doc. I know it might be a long shot, but I figure it was worth asking people that have more MathCad experience than I do, since I am pretty much self-taught from the Mathcad manual.

If this is not possible, do you guys have any suggestions as to what would be a more effective process? Currently, we are running into issues where there is too much room for error in the transposition of results. Myself or someone else trying to accurately read and re-write 50-60 different numbers can easily get a fit of dyslexia and screw something up.
Replies continue below

Recommended for you

RE: Generating reports in Word from MathCad calculations

M11 came with an Excel add-in that works in Excel, so you could output the results into Excel, and embed the Excel sheet within the Word document.

TTFN
FAQ731-376: Eng-Tips.com Forum Policies

RE: Generating reports in Word from MathCad calculations

Use hidden regions in Mathcad?

RE: Generating reports in Word from MathCad calculations

Use one of Mathcad's file / data ouput components / functions to create an appropriate number of text files (ie, one for each point in the Word Document that you need).
Use Word's file import mechanism to link to those files.

http://voices.yahoo.com/how-embed-existing-files-i...

I usually use IFRs's suggested method of putting all of my equations in an Area and collapsing it. However, it may require some work to restructure a worksheet retrospectively and the file-read route may be easier.

RE: Generating reports in Word from MathCad calculations

(OP)
Thanks for the input guys! I hadn't ever heard of the hidden regions, I may see if I can do something with that and write my report directly into MathCad.

Is there a way to sequentially show a solution in MathCad? That's not really the term I would use to describe it, but for example, I have many different spots where I currently have something that defines an equation, and then solves the equation for the report. Example (not really in the report, but easy to visualize)=

"sqrt(a2 + b2) = c .... Pythagorean Theorem. (a and b are previously defined in the report somewhere),

c = XX"

Is there a way to go directly from the definition to the answer without requesting c in the program? Like this:

"sqrt(a2 + b2) = c = XX"

I don't think there is, but it would make it much more simple to present in MathCad this way if I can! I've tried just bolding my solutions, but it bolds every constant/variable in every equation, whether it be a definition or a result.

Sorry for the newcomer questions, I have never used MathCad outside of generic problem solving! And thanks for the tips so far!

RE: Generating reports in Word from MathCad calculations

In newer versions of mathcad you can do what you want, but I'm unsure when it was implemented. I know with V14 I am able to do that, but with mathcad 2000 I can't.

RE: Generating reports in Word from MathCad calculations

(OP)
structSU10,

In your version, how do you do it? If I define an equation, it won't let me hit an equal sign in the same equation. If you can tell me how you do it in 14, I'll try it in 11.

RE: Generating reports in Word from MathCad calculations

Yea, its as simple as that, just hitting the equal sign after defining the equation. A way you could work around it is type the equation as text and then go to instert>math region and do the C : , it should look the same, and will still be a live calculation.

RE: Generating reports in Word from MathCad calculations

You can, you can use <CTRL>= instead of just =, which calls up the constraint operator used in solve blocks. This results in a dead expression, though, but can be used for the purposes of illustration and documentation.

TTFN
FAQ731-376: Eng-Tips.com Forum Policies

RE: Generating reports in Word from MathCad calculations

Quote (EMorel)

I hadn't ever heard of the hidden regions, I may see if I can do something with that and write my report directly into MathCad.
Just for the sake of terminological exactitude, I'm not sure that Mathcad in any variant can hide individual regions but what it can do is define a section of a worksheet as an "Area". An Area is bounded by two horizontal markers that span the width of the worksheet. An Area can be named and can be "Collapsed"; collapsing an area effectively rolls up the bottom marker to meet the top marker, thus 'hiding' all the regions that it contains. You can password protect an Area to stop casual users from expanding it (useful for both protecting your intellectual property and for stopping the ignorant from messing with things and then complaining it don't work no more! evil). However, whilst Areas are definitely useful, they won't allow you to show an equation and result side-by-side but they might allow you to hide a lot of "detail".

Mathcad 11, as you've probably found out, doesn't have the inline "c:=a+b=" facility ... I think it was introduced in Mathcad 12 (which, version you fortunately can't get anymore unless you're very unlucky).

RE: Generating reports in Word from MathCad calculations

(OP)
Excognito,

Thank you for the explanation, I did discover the usefulness of Areas and collapsing them, though for this report instance it wont do me much good.

So, after 12 they removed the feature to have "c:=a+b=" ?? This program is pretty awesome, but that seems odd. lol

RE: Generating reports in Word from MathCad calculations

Sorry, did I give that impression? No, they ADDED the capability in M12 - it's not in Mathcad 11 (or, at least, it's not in mine!). It's definitely in M15 and Mathcad Prime 2.0.

RE: Generating reports in Word from MathCad calculations

(OP)
Ah, got it, I read that as It was introduced in 12... you cant get it anymore. lol

RE: Generating reports in Word from MathCad calculations

No, luckily you can't get V12 anymore. It was absolutely the worst, buggiest, piece of junk that MathSoft ever produced and was a factor in them having to get rescued by PTC.

Sounds like there is enough information above to do what you want within MathCad directly. In any version back to about V0.5 you can type <cntl>= to put anything you want equal to anything else (and as many times as you want) and it is not evaluated outside a program or a solve block. So

c<cntl>=sqrt(a2+b2<cntl>=5cm

Is perfectly acceptable to the parser. You could put a:3 cm, b:4 cm, c:sqrt(a2+b2) in a collapsed area and type the answer into your <cntl>= expression. This has the risk that you won't update the hard number if conditions change.

I did:
a:3cm
b:4cm
c:sqrt(a2+b2 c=5cm

in actual documents for 10 years and did't feel like it detracted much from the people who wanted to follow the math. Getting headers, footers, and pagination right in MathCad is always a challenge, but sometimes it is worth it.

David Simpson, PE
MuleShoe Engineering

"Belief" is the acceptance of an hypotheses in the absence of data.
"Prejudice" is having an opinion not supported by the preponderance of the data.
"Knowledge" is only found through the accumulation and analysis of data.

RE: Generating reports in Word from MathCad calculations

In my last post please pretend that if a closing parentheses is required but missing, then I meant to put it in the proper place.

David Simpson, PE
MuleShoe Engineering

"Belief" is the acceptance of an hypotheses in the absence of data.
"Prejudice" is having an opinion not supported by the preponderance of the data.
"Knowledge" is only found through the accumulation and analysis of data.

RE: Generating reports in Word from MathCad calculations

(OP)
Zdas04, I understand what you're saying about the <ctrl>=, but as you said, the problem is that it won't update if parameters change, which is the point of doing it all in MathCad instead of transposing to a separate report.

Looks like I'm going to be pushing the company for a later version, because being able to do the "c:=a+b=XX" would GREATLY clean up this report. Luckily, MathCad isn't the most expensive program out there!

RE: Generating reports in Word from MathCad calculations

The only point is you get the appearance of a function you wanted. Once I retired and started my own business I started using MathType for equations in the body of a report and just generated appendix in native MathCAD (with areas hidden). That works for me.

If you get a new version of MathCAD and start using the == stuff you need to be really careful to make sure that everything updates with a change. In V14 that doesn't happen most of the time. I end up having to put the cursor on every equation and hit F9 to make sure that I'm seeing the current stuff. Can be frustrating. Not enough to go to V15.

David Simpson, PE
MuleShoe Engineering

"Belief" is the acceptance of an hypotheses in the absence of data.
"Prejudice" is having an opinion not supported by the preponderance of the data.
"Knowledge" is only found through the accumulation and analysis of data.

RE: Generating reports in Word from MathCad calculations

(OP)
So if I were to update my MC, what version would be ideal? Can I still get older versions before Prime? From what I'm reading, Prime 2.0 is a step backwards from 11? Keep in mind that I don't use MathCad for many things, and I only have a library of about 10 worksheets that, if necessary, I could re-write in a newer version. I'm not doing anything outrageous either, the hardest equations require only the basic principals of calculus, the rest is basically algebra, just a lot of it.

RE: Generating reports in Word from MathCad calculations

If you intend to upgrade, go for version 15. Not only is it the currently supported version, but it is also, in my opinion, the best of the post V11 versions. If your needs are limited as you describe, then you might like to try Prime 2. It's still not up to M11/M15 standards, but it still reasonably capable and looks slightly more "professional" in some respects. Prime actually has a few advantages over M15 in that it has dropped the static type checking introduced in M12 onwards and added mixed units in arrays. You get M15 for free if you buy Prime.

RE: Generating reports in Word from MathCad calculations

According to PTC's published roadmap for Mathcad, M15 will be supported with maintenance releases through 2014, and MP3 is to be released sometime this year.

TTFN
FAQ731-376: Eng-Tips.com Forum Policies

RE: Generating reports in Word from MathCad calculations

Thanks for the tip about "c:=a+b=XX". I'm always typing a second c:= so I can follow the results throughout a calculation. But it's not too useful if M14 doesn't reliably update the results when the inputs change. I've tried it in a few files and it seems to be working for me. Is this a real bug? Is it fixed in M15?

----------------------------------------

The Help for this program was created in Windows Help format, which depends on a feature that isn't included in this version of Windows.

RE: Generating reports in Word from MathCad calculations

Your second C:= should be just C= to report the calculated value of C. It always works for me in M15. Note: you can also imbed results in text, like "In the end, C=XX when rounded to two places" where C=XX is actually the same as C= somewhere in the document. I actually hate Word for calculations, since Mathcad does such a better job, and I have figured out headers, footers, page border, pagination, etc. Putting CAD drawings or pictures into Mathcad is easy also.

RE: Generating reports in Word from MathCad calculations

I recently introduced a college student to Prime 2 and for a new user, it is pretty nice as compared to M15. For easy simple calculations and presentations, it is actually OK.

RE: Generating reports in Word from MathCad calculations

(OP)
IFRs, that's my thing too, I hate using the equation editor in Word, especially when I'm already using MathCad to generate all of the results. I figure with a later version of MathCad, I can create a report that looks near identical to the one I have in Word and eliminate the need for me to transpose anything!

RE: Generating reports in Word from MathCad calculations

I installed V15 within days of introduction. I had a lot of problems with some of my old sheets not working anymore. Switched back to V14 where I knew what bugs to avoid. I've heard there were some fixes to V15 that made it very stable, but I never went back. From the comments above maybe I should have.

The second equal sign not updating seems to kick in when the sheet gets to a certain size. The sheet where I first noticed it was 2.1 MB. Under 100kB the second = always updates just fine. When I first saw it a couple of years ago I started a thread here or in Tek-tips.com and it seemed to be a known bug. I can't find the thread now and I can't remember many details.

David Simpson, PE
MuleShoe Engineering

"Belief" is the acceptance of an hypotheses in the absence of data.
"Prejudice" is having an opinion not supported by the preponderance of the data.
"Knowledge" is only found through the accumulation and analysis of data.

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



News


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