Dedicated forum for our customers to share, collaborate, discuss best practices.
Recently active
Is there any way to send excel data into Matchcad using VBA. I have many claculation work on mathcad but I want excel to be use as an input body which send the specific cell data to a variable in mathcad and the mathcad run the calculation. after that vba send the message to print the mathcad worksheet Example is here to understand Step 1 In excel sheet, we have let say three values in three cells variable with values such as a is 350, b is 505 and c is 900 and so on (actually I have more than 100 values) Step 2 Excel vba open mathcad using COM or API (I do not know the code yet and how to open mathcad from excel vba) Step 3 Excel sent a, b, and c value in mathcad. where many operation are performed such addition, square and many more using these a,b and. Step 4 Excel send signal to print mathcad and then close the mathcad worksheet. Note: Please note the actual work is much more complicated it has atlead 60 pages of calculation in mathcad and more than 1
Hi There ,I have two functions are exactly the same but in two different sheet in the first sheet . it works perfectly and I’m getting the expected answers for f2In the second sheet it doesn't work and I suspect the reason is M has different arrays . How can I fix this function : the error says : This array index is invalid. The index must be an integer, not less than ORIGIN, and not greater than the last element."I can’t attached simplified sheet even in zip file. I hope you can help Thanks in advance , Yusra
Hi. I am trying to use an advanced list box to select a beam section from the first column in a matrix that I can then use to lookup related properties further on in my calc sheet. The problem I have is that the selection does not get parsed to the output variable. Any help with this would be appreciated, I can’t seem to find anything useful online, but I am clearly missing some detail.Here is the list box code and MathCAD file attached. // TODO: Add your initialization code herefunction ListBoxEvent_Start(Inputs, Outputs) { // TODO: Add your code here};function ListBoxEvent_Exec(Inputs, Outputs) { // 1. Clear the list box contents FIRST to reset it ListBox.ResetContent(); var options = Inputs[0].Value; // 2. Loop through and add the strings for(var i=0; i < options.length; i++) { ListBox.AddString(options[i]); } // 3. Set your output Outputs[0].Value = options[ListBox.CurSel()]; //Outputs[0].Value = ListBox.get_text(ListBox.CurSel());};function ListBoxEvent_Stop(Inputs,
Hello,I am new to developing custom functions for Mathcad Prime.I already managed to create a working custom function in C, but I still cannot understand how to do the same in C++.To be honest, I do not understand the internal structure of Visual Studio C++ projects yet. I am learning step by step and using AI to help me understand the code and project structure.My goal is to move large engineering calculations from Mathcad into C++ DLL libraries. I hope to use AI to help convert my Mathcad algorithms into C++, but first I need to understand how a working C++ custom function project is organized.At the moment I cannot even create a very simple function like:int add(int a, int b){ return a + b;}I am not asking anyone to write my project for me.I would simply like to have a minimal Visual Studio C++ project that builds into a DLL and is recognized by Mathcad Prime. Even a project containing only one simple function would be enough.Once I have one working example, I believe I will be a
Hello, I'm having trouble developing a loop that includes break and return statements for buckling analysis. I'm also having trouble generating a combo list for the K values.
I need to evaluate anchored walls, according to FHWA Circular 10, for various strata, but I've had problems with the definition of a vector i. This new version of Circular 11 changes the definition of a vector, so could you help me with this problem?Regards.For loop and return for a vector i
Hi, as you can seeat the bottom of the picture, when evaluting the function “Iresonance”, instead of replacing the variable with the actual, it gives “function” in the result, but the function “wresonace” is already defined. How to subtitute it? Thanks
Hi, I’m just trying to get the real and imaginary part from a complex number, but the result is just not right.
Hi there , How can I work in Mathcad faster. it freezes when I use large data I have to use loop functions , however , it took so much time and doesn't calculate I have to close it and open it again and still doesn’t work Thanks, Yusra
I would like to use the result of a quadratic function for another mathematical operation. Example: F(x)=4x^2+x-3 gives the results -1.0 and 0.75. I would like to use the value 0.75 for another operation. Please give me some tips on how to write this in Mathcad.
Hi There , I always face this error and I don’t know how to solve this . I need to find the difference between 2 levels in same z which has 4 rows like it do the same calculation for each row separately Than I have to find the average and minimum value for this results I attached simpler mathcad in zip file
Hi community,I’m coping a program to make tables but get errors?What's wrong?Regards,CarlosRomero PD. This routine can be used with either vectors or your beloved ranges as arguments. First we create a function which tables a function with three arguments, so that the result is a nested array consisting of a vector of matrizes. Ever of those matrices shows the function values whith constant third argument z and x as rows and y as columns.
Hi Everyone I’m doing the same calculation in two different sheets , but I get errors in the another one although they are the same . why is that ? thanks Yusra
pls i need this thing
Dear all, Hope everyone is doing well. I am using Mathcad Prime 8 and I am trying to find a way to convert a pdf (originally a mathcad file) into a mathcad file (e.g. mcdx). There are formula equations in that file and so far when I try adding the file into Mathcad, the formulas are not recognized. Is there any way to do this? Best regards,Vich
How can I make sure that e_max is added correctly … non of them has units , but still getting this error Thanks Yusra
Hi,Another Odesolve problem with an error I cannot identify. Google AI says its a syntax problem but I am damned if I can see it.Any assuistance would be appreciated.Regards, Ross
PrimeConnect C++ -> Prime -> C++PrimeConnect is a pair of C++ solutions/projects.One writes a *.mcdx Prime output file fully described by C++ syntax that encapsulates the mathematics of a Prime Worksheet.Two reads a *.mcdx Prime input file where all evaluation regions of a Prime Worksheet can be assigned to C++ variables in one line each.They both work on the underlying feature of *.mcdx files that are a collection of zipped XML files. In the case of Prime text regions zipped up zipped files of text.The underlying XML text manipulations are handled invisibly by PrimeConnect. User of C++ can concentrate on the mathematics when writing a *.mcdx file. User can concentrate on what are all the evaluation regions in a Prime worksheet are and assign them to C++ variables.Writes Prime v10 files, Reads Prime v9, v10, and v11 files without varying C++ code just point the C++ to a *.mcdx file.Both Microsoft Visual Studio 2022 C++, and Embarcadero RAD Studio 12 projects are available. The
Hi there, I don’t know why it shows this error here . I used the same function in another sheet and it is working Regards,Yusra
Hi there ,I want to write : if z_top,j > Hphr → use γ (unsaturated)if z_top,j < Hphr → use γsatbut I end up with this red box … the blue box is only using γ (unsaturated)can you please help me fixing this ?Thanks Yusra
Reference topicThere does seem to be a bug with Polyroots. I get the same error with the Quicksheet and a manually entered matrix of coefficients.If anyone can advise how to fix this issue your advice would be appreciated. Ross
I recently started using Mathcad Prime 12 for structural engineering / Eurocode calculations and I noticed something frustrating regarding the unit system.Mathcad correctly understands that: kg/s² = N/m. However when working with line loads (common in structural engineering), Prime often displays results as “kg/s²” instead of the expected engineering SI unit: N/m or kN/m.The strange part is that under “Insert Derived Units → Force per Length” there are several imperial units available: kpi, klf, plf. but there is NO SI alternative such as N/m or kN/m.This creates a awkward workflow in SI-based calculations, especially for Eurocode and structural design where line loads are constantly used.Currently the only workaround that i found seems to be manually dividing by (kN/m) , creating display variables or manually writing the unit as text. This partly defeats the purpose of the otherwise very capable engineering unit system.Questions:Is there any hidden way to add custom SI derived units
Hello All, The following symbolic evaluation used to calculate without any issues in mathcad 15. It does not evaluate in Mathcad Prime 11.0.1.0. i have attached the sheet,Regards,Sam
Hi all,Last week we released PTC Mathcad Prime 12.0.0.0. We’ll be sharing more detail on www.ptc.com soon. A handful of users reported an issue with the release.Currently, PTC Mathcad Prime 12.0.0.0 will not run if it’s installed on a system where the system language is set to one other than one of the ten languages officially supported by Mathcad (US English, French, German, Italian, Spanish, Japanese, Korean, Russian, Simplified Chinese, and Traditional Chinese). If you run Mathcad Prime 12.0.0.0 on a system using one of those supported languages, there’s no problem. If you can change your system language to one of those supported languages, Mathcad Prime 12.0.0.0 will run fine. But if you need to run Mathcad Prime 12.0.0.0 on a system language not officially supported by Mathcad, you should remain on PTC Mathcad Prime 11.0.1.0 until this is resolved.We’ve been working closely with Microsoft on this issue and have identified a fix. We’re currently in the process of building and testi
This month’s challenge is inspired by the greatest rock band of all time: Rush! Specifically, it is in honor of the 50th anniversary of their concept album 2112, which gave us the Starman logo. Here you can see the logo along with geometry in Creo pertaining to the challenge:Starman Star Challenge depicted in Creo ParametricNote that the Starman logo is not a pentagram, and Rush is not devil-worshipping music (as many of our parents thought). Drummer and lyricist Neil Peart (RIP) was really into Ayn Rand (which is arguably worse). The logo represents a naked man, armed only with his intellect, resisting the collectivism of the Solar Federation. Listen to the album. It’s awesome.Here is the challenge: start with a circle of radius 1. Inscribe a regular pentagon. Connect the vertices to form a star.Challenge 1: Measure the area of (1) the star, (2) the pentagon inside of the star, and (3) the tips of the star (the star minus the interior pentagon).Challenge 2: Write functions for these a
Already have an account? Login
No account yet? Create an account
Enter your E-mail address. We'll send you an e-mail with instructions to reset your password.