cancel
Showing results for
Did you mean:
cancel
Showing results for
Did you mean:

Community Tip - If community subscription notifications are filling up your inbox you can set up a daily digest and get all your notifications in a single email. X

7-Bedrock

## Solve block

Hello

17 REPLIES 17
23-Emerald I
(To:AS_9781967)

Well, there are a few things that need to be corrected to make the solve block work, but do you really need a solve block?

Attached file (Prime 4.0) explains.

7-Bedrock
(To:Fred_Kohlhepp)

I tried the way you suggested however i am unable to get the answer any suggestions where I might went wrong?

21-Topaz I
(To:AS_9781967)

Hi,

Two things.

1) You can include the worksheet to help solve your problem.

2) Can you give a little more insight into the problem you are solving?

24-Ruby V
(To:AS_9781967)

Prime can't solve integral equations, but it can solve some differential equation (at least numerically).
Not sure if the following would come close to what you are looking for (note that a^2/|a|=|a|)

The simple ODE can easily solved symbolically by hand (separable variables ), of course

P6 worksheet attached

7-Bedrock
(To:Werner_E)

Related question: what if you have you have two velocities (e.g. velocity in the x and y directions) that effect each other.  Such as when the spin on a effects trajectory.

23-Emerald I
(To:AS_9781967)

You can deal with that easily.  Attached is an Express file that solves both the original problem and the two dimensional one with Euler's method, Express cannot do solve blocks and ODESOLVE.)

23-Emerald III
(To:AS_9781967)

You can read in the online help information how you need to set up a solve block with Odesolve to solve a set of differential equations:

So in your case that would be solmething like:

But you also have to be consistent. Those (t)'s are necessary (red arrows).

This may be the result:

Prime4 file attached.

Success!
Luc

7-Bedrock
(To:LucMeekes)

Thanks again for the help.  It looks like it’s working except, when I add the correct units to the parameters, I get an error that says “the units are not compatible”.  Can you tell me what the problem is

23-Emerald I
(To:AS_9781967)

Prime has different labels for things:

Units are blue bold text:

If Prime gets the labels wrong: (note the difference, mi/hr are not units)

Then the units won't balance and Prime throws a flag.  (The units in your equation for acceleration don't balance anyway!)

Attached is another file; it starts the same as my previous one, but I've added to it using units (and deriving drag and spin equations for a baseball.)  Hope it helps!

7-Bedrock
(To:Fred_Kohlhepp)

Thank you for the details Fred.  Can you please tell me what's missing in the file I attached I changed the label to units and still it dont work? What units should be used in my file to make it work as i wanted to have it simplified

23-Emerald III
(To:AS_9781967)

I think it should work as in the attached. (I'm also limited to Express, solve block's don't work.)

Success!
Luc

7-Bedrock
(To:LucMeekes)

After applying the units from above worksheet it is giving me error "The calculation is not converging to a solution..." Any thoughts?

21-Topaz I
(To:AS_9781967)

Hi,

The solve block works when you limit the range of the ODESolve to 17 s of range.

You can see why from the graph of the solution.

See enclosed file.

Can you let me know  instead of solve for positions and velocities at specific times given constants like initial position, velocity, drag and spin, what if I instead want to solve for these values, such as in the attached worksheet?

23-Emerald III
(To:AS_9781967)

You have a few odd things in there.

Your D is undefined, I suppose the - should be a :=

It seems that you have a system of non-linear differential equations (DE) that you need to solve. There are two functions of t, Vx(t) and Vy(t) that are undefined. To solve that, the solve block should probably end with an Odesolve, not with Find. And you don't need guess values, but I think it doesn't hurt to use that space for defining some constants.

Two of the guess values defined are Vx and Vy. Now this is a problem, because the DE also uses these symbols, but as functions of t. I should guess you want to provide the initial conditions V0x and V0y instead...

Then, for a system of DE with two functions and order 1, you can have only 2 initial conditions, you provide 8.

I wonder if the system is solvable without all those integral expressions.

Success!
Luc

7-Bedrock
(To:LucMeekes)

Thank you for the input.  Ultimately, what I’m trying to do is to determine the values for the variables listed in the “Guess Values” section of the solve block that “best fit” the expressions in the “Constraints” section of the solve block.  NOTE: the six integrands listed at the bottom of the “constraints” are data that were collected on the system.  I would like to have the ability to add even more data and use something like a “miner” function to fit it to the expressions.  How would you suggest I do that?

21-Topaz I
(To:AS_9781967)

Hi,

Look up in help: "About Curve Fitting Functions"

There you will find what you seek

Cheers

Terry

Announcements