Solve blocks are a Mathcad construct that lets you solve any number of equations and unknown variables.

The function Find returns a solution to a system of equations given by a solve block. You can use Find to solve a linear system or nonlinear systems.

**How to Use Mathcad Prime Solve Blocks**

- Insert a Solve Block from the Math tab and add two guess values. Note that the Guess Values label moves to bracket that section. The algorithm for Find starts at these values and moves toward a solution.The solve block box allows you to reposition the solve block on the page, without worrying about losing any of the pieces. Definitions inside the solve block are local to the solve block.
- Next add your constraints. You must have the same number of constraints as variables you are solving. You do not need the word Given, unlike earlier versions of Mathcad.
- For the equals sign, use the Boolean Equals operator, Ctrl+=Note: The entries of the solution vector correspond to the variables in the same order that the variables appear after Find. Type in Find(y, x) to return the entries in reverse order. Evaluate the left-hand sides of the system with the found results to confirm that the solution is correct.

**Multiple Solutions **

Take a look at the solve block below.

The first equation represents an ellipse, while the second represents a straight line. These are plotted below, along with the solution point.

As the graph shows, the solution corresponds to the point in the first quadrant where the curve and the line intersect. However, there is another solution to the system, corresponding to the point of intersection in the second quadrant. How can you get Find to return this second solution?

**Change the Guess Value**

Changing the guess values reveals other solutions. Keep in mind that the result returned by the function Find (as well as by the functions Minerr, Minimize, and Maximize) is directly related to the guess values for the unknown variables, and at most one solution is returned for a given set of guess values.

So changing the guess values might lead to a different solution.

Looking at the graph above, you can see that the second solution lies in the second quadrant. So it seems reasonable to try guess values corresponding to a point – the guess point – that also lies in the second quadrant. Try the guess point (-3, 3).

This time Find returns the second solution.

Usually, if you choose a guess point close to a solution, Find returns that solution. However, as with the root function, Find does not always return the solution that is closest to the given guess point.

You can see the relationship between guess points and their corresponding solutions graphically by defining a function that takes a guess point to the resulting solution.

For any guess point (x, y), the function Pt(x,y) returns one of the two solutions. For example:Now, see what happens when you apply the Pt function to 25 guess points, equally spaced on a circle of radius 4 with center at the origin. Draw a line from each guess point to the solution produced by the Pt function for that guess. The resulting plot is quite interesting. By changing the guess point, you can find both possible solutions.

Notice that most guess points in the right half-plane (x > 0) lead to the solution (4,3). However, some points in the right half-plane lead to the solution (-3.71, 0.657)Try changing R to 6 in the example above to see what happens when the guess points lie on a circle of radius 6.

Find uses the Levenberg-Marquardt method, a very stable routine that is tolerant of poor guesses.

What these examples show is that choosing guess values is actually a guessing game. A picture can help you identify the guess points that return the solutions you are looking for.

There’s lots more to learn about solve blocks, but this should get you going. Part two of this article will discuss what to do when the solve block does not find a solution.

>> Visit the Mathcad Community website for the Mathcad Prime 1.0 and Mathcad 15 worksheets.

Pingback: Forex Power Trading System

I have problems solving something a little diferent than what’s shown. Can I get any help here?

Mathias,

A good resource for help is the Mathcad Community: http://communities.ptc.com/community/mathcad

You can ask questions there and even upload a worksheet so others can see the problem. The Community members are very willing to help!

Bettina

Pingback: Happy 3rd Birthday to the Mathcad Blog! | PTC

Pingback: Calculating the Probability of Failure for Anti-Friction Bearings in Mathcad Prime 2.0 | PTC

use Gauss method, it is the simple method to solve the “system of equations.

What is the shortcut to implement Find()? I type it in and it doesn’t do anything?

“find” must be part of a solve block — it will not work outside. Simply type “find(” you will notice that it changes font as you type “(“. This is because the KEYWORD label is applied. You can also apply the KEYWORD label using Labels drop-down on the Math tab. Hope this helps.

Another way to get started with solve blocks is to search help for Solve Block examples. You can copy equations from help into the worksheet.

Pingback: Happy 4th Birthday to the PTC Mathcad Blog! | PTC

How could you solve a system of equations that have a greater number of constraints than variables in Mathcad?

Hi Kyle- we’ve attached examples of how to do this here: http://communities.ptc.com/docs/DOC-4237

How did you plot the equation 2x^3 + 3y^2 = 59?

Can Mathcad Prime plot implicit functions/equations? I tried in my Mathcad but only get error messages.

Your suspicions are correct. Mathcad Prime does not support the plotting of implicit equations. The red circle you’re referring to was most likely generated with two functions: +/- sqrt(59 – 2*x^2) / 3.