Eng-Tips is the largest engineering community on the Internet

Intelligent Work Forums for Engineering Professionals

Simplify an Array Operation 1

Status
Not open for further replies.

Sparweb

Aerospace
May 21, 2003
5,103
0
36
CA
I'm looking for a simple array operator (or combination of operators) that will do the same thing that I currently only can do by explicitly computing the value for every element.
Somehow, I can't find an array operator that will select the values in two arrays, subtract them, and then store them in a resulting array.

To picture what I'm doing, think of a box with several compartments. The air pressure in each compartment is different. The difference in air pressure on each of the walls determines the force on each wall.
Sounds like a simple problem, but I can't find the operator that will solve this when I store the pressures in an array.

An example of what I am trying to do is attached below.
I also included in my attachment a "forced" answer where I manually calculate the answer and show the correct result. It shouldn't be that hard.


STF
 
 http://files.engineering.com/getfile.aspx?folder=23e72b6d-126e-40ef-b25c-a60ad722c80d&file=matrix_math_STF.xmcd
Replies continue below

Recommended for you

Like this?

matrix_math_iz2tx5.gif


TTFN (ta ta for now)
I can do absolutely anything. I'm an expert! faq731-376 forum1529 Entire Forum list
 
Y'know, a little voice was saying it was going to be obvious when I saw the answer.

Consider my forehead to be firmly slapped!


STF
 
Status
Not open for further replies.
Back
Top