Quantcast
Channel: PTC Community : All Content - PTC Mathcad
Viewing all articles
Browse latest Browse all 3331

Converting the results of ODESOLVE in different coordinates in PRIME 2.0

$
0
0

Hello Mathcad-Community,

 

I need help on converting the results of a solved differential equation in different coordinates in Mathcad Prime 2.0. Some days ago, I had a problem solving a system of 5 differential equation (some of you might remember). It was about a stream of gas flowing out of a broken tank/pipeline while experiencing wind from one side.

Before I got the equations to start the solving process, I had to convert the coordinates from cartesian to curvilinear coordinates. So actually i changed x,y and z to s (distance from the source in the center of the stream), r (distance from center of the stream) and the angel phi (you can imagine that as a rotation around the center of the stream). The direction of the wind is directed parallel to the y-axis. Maybe this scetch will help: EDIT: you can find the scetch in my file. I tried to implement it in the text, but it didn't work. It's at the top of the file below.

 

With the 5 differential equations, I was able to calculate the concentration c, Temperature T, Speed u, broadth of the stream b and the angle Theta between the s- and the y-Axis. The stream is axisymmetric, so the value for example c, or T at a certain distance r from the center of the stream is the same for every angle Phi around the axis.

If i take for example the concentration c, I am able to calculate the concentration for every point, dependant on s and r (its the same for all values of Phi, if s and r are known). If I want to know where this point is in cartesian coordinates, I have to use the equations for x, y and z below the charts in my added file. (you can ignore the whole part before the charts, this part works!)

 

What i want to do now is to re-convert the function into cartesian coordinates, or at least create a new function that does all the work of calculating point for point, so I don't have to do this by hand. I thought about creating a matrix with all the results for (for example) c(s,r) and a new function that takes out point after point of that matrix and converts it into x,y and z coordinates with the 3 functions in my file, but I don't know how that works.

 

Do you guys have an idea and could maybe help me?

 

Any help would be appreciated.

 

Regards

 

Tim


Viewing all articles
Browse latest Browse all 3331

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>