Hi Mark,

Thanks for the welcome. After a 20 year hiatus from programmable calculators spent mostly on Excel sheets I'm back into programming.

I´m a Chemical Engineer working in an Oil refinery in the Middle East.

It all started with Pump Curves. Since the statistics and curve adjustment is super friendly, plus the polynomial coefficients have more significant digits, hence more accuracy. I basically simulated the pump curve parameters for a series of pumps.

It all started with the need of having pump curves in the palm of my hand. Head, Efficiency, Power and NPSH all as a function of the flow Q. So I made separate programs for each variable of each Pump. The functions are described below.

H(Q)= Head as a function of flow Q. 4th Degree polynomial.

Eff(Q)= Efficiency as a function of flow Q. 3rd degree Polynomial.

SP(Q)=Shaft power as a function of flow Q. Linear.

NPSH(Q)= Net Positive Suction Head as a function of flow Q. Exponential.

All well here, then I ask myself, what if I just make a program to return all these functions at once by just entering the flow?

Then I faced my first road block: You cant use RETURN multiple times in the program, it will only return the function on the first return line.

Then I bump into this tutorial blog by Eddie Shore:

https://edspi31415.blogspot.com/2013/10/...8245762045
The Solution: A Vector!

So you basically would type:

RETURN [H(Q),Eff(Q),SP(Q),NPSH(Q)];

Of course not these expressions as is, but the respective actual Polynomials or Functions.

Now I have a program that returns all the information at once by entering the flow.

The thing is that now my calculator is cluttered with the vector program and the individual functions.

So end up with programs like

PUMP1H(Q)

PUMP1Eff(Q)

PUMP1SP(Q)

PUMP1NPSH(Q)

And the Vector expression which groups them all.

PUMP1HEPN(Q)

Here´s my conundrum...I have more than 20 pumps to look after.I have done this for only 4 so far so it would take 100 programs to scroll through to solve the function.

Generally, on the field, the easiest of these functions to solve for Q is the head. Power is also relatively easy to estimate.

So when I want to check the flow against the flow meter I would determine the head, lets call it h, and use use for example

SOLVE(PUMP1H(Q)=h,Q); h i an actual number in this case.

Then the Prime will return the flow Q.

What I want to accomplish is just to keep the vector program to declutter the scrolling list then solve using the only known value is h.

Something like:

SOLVE(PUMP1HEPN(Q)=[h,unknown,unknown, unknown]);

In this part I have not succeded so far and where I am looking for someone to give me a clue on how to proceed.

Greetings from the desert,

Boris