cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Check out the JMP® Marketplace featured Capability Explorer add-in
Choose Language Hide Translation Bar
LearningSigma
Level II

Pump variable modeling

Hello, I am trying to model variable speed pool pump parameters: runtimes, speeds, and flow rates in order to minimize my power bill, but also achieve decent flow. I've hit a stumbling block with modeling the data.

Pump constraints: Max 24 hr run duration, Max of 3 speeds can be used per day, Speed increments are 2 hr blocks (0,2,4,6...24) 

 

Example Pump Data:

RPM Flow Power

500 17 63
750 24 92
1000 29 132
1250 35 185
1500 41 260
1750 50 370
2000 57 515
2250 65 700
2500 75 926
2750 79 1210
3000 90 1540
3250 98 1920
3450 107 2290

 

What is the best way to model this in JMP 13? I

6 REPLIES 6

Re: Pump variable modeling

Please attach your data as a JMP data table in the future. I spent time copying it to a JMP data table as a single character data column and then split it into three numeric data columns.

 

The simplest model is usually the best. You are interested in predicting the effect, not in explaining the effect. I plotted the data first.

 

dist.PNG

multi.PNG

 

The Speed and Pump Flow are highly, linearly correlated, so both of them cannot be used as predictors in any type of model. I chose Speed as the predictor of Power. The relationship is curvilinear.

 

curve.PNG

 

Several models were fit to the data. The Cubic Polynomial model is the best by far based on AICc.

 

I attached the JMP data table with your data and several saved table scripts to reproduce my analysis.

LearningSigma
Level II

Re: Pump variable modeling

Hi Mark,

Thanks for this part of the answer. How can we take this data and make an interactive model simulating 1-3 speeds / 1-3 run times / with a goal of 43000 gal of total volume, but optimize the energy use and volume moved in a day?

 

Goals: minimize energy use, but using at least 1 speed of the 3 speeds >=2500 (can use 2 other speeds/run times if needed), move at least 43000 gal in a day.

 

At a cost of $0.13/kw for example:

2750 RPM @4 Hrs = $0.84 and 18960 gal

1500 RPM @4 Hrs = $0.18 and 9840 gal

1000 RPM @8 Hrs = $0.18 and 13920 gal

 

 

LearningSigma
Level II

Re: Pump variable modeling

These 3 runs combined are the daily power of $1.2 and 42720 gal of flow

Re: Pump variable modeling

Run the selected model and save it as a column formula. Then open the Profiler with the column formula. The Profiler is the easiest way to evaluate different settings.

 

You need a column for Run Time and another for Cost. You can add Cost as a second response, or maybe it is the primary response.

ih
Super User (Alumni) ih
Super User (Alumni)

Re: Pump variable modeling

Is the pump speed ordinal, or can you set something in between those values?  If it is continuous then it seems the optimal value would be as slow as possible as the specific power always decreases with lower flow.  You could find that optimal flow given your constraints using the profiler as @Mark_Bailey suggests.  Here is how I did it, run the script below to recreate the table with saved scripts.

  • Calculate specific power in a new column, or the power per unit of flow
  • Calculate flow in gal/day in a new column (I assumed the flow is gpm)
  • Model the flow based on the pump speed. I used a neural network because it captured the visual curve in the data while giving smooth response between points and without responding to what looks like noise around 2500-3000 RPM, save the profiler prediction formula. (Script 1)
  • Model the specific power, again a neural networked and saved the profiler formula (Script 2)
  • Check the predicted versus actual values for reasonableness (Script 3)
  • Use column properties to set a lower spec on the flow and a a response limit to minimize specific power
  • Found optimal conditions using the profiler, using both predicted columns in the y and rpm in the X.  Used Maximize Desirability to find the optimal pump setting. (Script 5)

ih_0-1685482391861.png

 

View more...
New Table( "Maximize Pump",
	Add Rows( 13 ),
	New Script(
		"1 Model Flow (gal/day) by RPM with NN",
		Neural(
			Y( :"Flow (gal/day)"n ),
			X( :RPM ),
			Informative Missing( 0 ),
			Validation Method( "Holdback", 0.3333 ),
			Fit(
				NTanH( 3 ),
				Profiler( 1, Term Value( RPM( 2637, Lock( 0 ), Show( 1 ) ) ) )
			)
		)
	),
	New Script(
		"2 Model Specific Power by RPM with NN",
		Neural(
			Y( :Specific Power ),
			X( :RPM ),
			Informative Missing( 0 ),
			Validation Method( "Holdback", 0.3333 ),
			Fit( NTanH( 3 ) )
		)
	),
	New Script(
		"3 Check for reasonable models using Graph Builder",
		Graph Builder(
			Size( 534, 456 ),
			Show Control Panel( 0 ),
			Variables(
				X( :RPM ),
				Y( :"Predicted Flow (gal/day)"n ),
				Y( :"Flow (gal/day)"n, Position( 1 ) ),
				Y( :Predicted Specific Power ),
				Y( :Specific Power, Position( 2 ) )
			),
			Elements(
				Position( 1, 1 ),
				Points( X, Y( 2 ), Legend( 3 ) ),
				Formula( X, Y( 1 ), Legend( 5 ) )
			),
			Elements(
				Position( 1, 2 ),
				Points( X, Y( 2 ), Legend( 6 ) ),
				Formula( X, Y( 1 ), Legend( 7 ) )
			),
			SendToReport(
				Dispatch(
					{},
					"graph title",
					TextEditBox,
					{Set Text( "Predicted and Actual Flow and Power per Flow" )}
				)
			)
		)
	),
	New Script( "4 Added spec and desirability function", . ),
	New Script(
		"5 Optimize with the Profiler",
		Profiler(
			Y( :"Predicted Flow (gal/day)"n, :Predicted Specific Power ),
			Profiler(
				1,
				Desirability Functions( 1 ),
				"Predicted Flow (gal/day)"n <<
				Response Limits(
					{Lower( 43000, 0.066 ), Middle( 43005, 0.5 ),
					Upper( 43010, 0.9819 ), Goal( "Maximize" ), Importance( 1 )}
				),
				Term Value( RPM( 1039.13398714365, Lock( 0 ), Show( 1 ) ) )
			)
		)
	),
	New Column( "RPM",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values(
			[500, 750, 1000, 1250, 1500, 1750, 2000, 2250, 2500, 2750, 3000, 3250,
			3450]
		)
	),
	New Column( "Flow",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values( [17, 24, 29, 35, 41, 50, 57, 65, 75, 79, 90, 98, 107] )
	),
	New Column( "Power",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Set Values(
			[63, 92, 132, 185, 260, 370, 515, 700, 926, 1210, 1540, 1920, 2290]
		)
	),
	New Column( "Specific Power",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Formula( :Power / :Flow )
	),
	New Column( "Flow (gal/day)",
		Numeric,
		"Continuous",
		Format( "Best", 12 ),
		Formula( :Flow * (60 * 24) )
	),
	New Column( "Predicted Flow (gal/day)",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 1 ),
		Set Property( "Notes", "Model NTanH(3) - Save Profile Formulas" ),
		Formula(
			(-4986263.94864684) + 12250231.3478716 *
			TanH( 0.5 * ((-0.195770498135355) + 0.00013382112616832 * :RPM) )
			+54339329.8694451 * TanH(
				0.5 * (0.227571869547046 + -0.0000279518693191086 * :RPM)
			) + -40377.1104869192 * TanH(
				0.5 * ((-1.66726266024003) + 0.00154547501582029 * :RPM)
			)
		),
		Set Property(
			"Predicting",
			{:"Flow (gal/day)"n, Creator( "Neural" ), Std Dev( 1578.4156263483 )}
		),
		Set Property( "Expand Intermediates", 1 ),
		Set Property( "Spec Limits", {LSL( 43000 ), Show Limits( 0 )} )
	),
	New Column( "Predicted Specific Power",
		Numeric,
		"Continuous",
		Format( "Fixed Dec", 12, 2 ),
		Set Property( "Notes", "Model NTanH(3) - Save Profile Formulas" ),
		Formula(
			99.4343260017528 + 5.9968762233528 * TanH(
				0.5 * ((-2.70046669266303) + 0.00107500481416692 * :RPM)
			) + -70.0855096923245 * TanH(
				0.5 * (0.536433235085508 + 0.000419373832905438 * :RPM)
			) + 191.605900251259 * TanH(
				0.5 * ((-0.790641306358042) + 0.000145038719985201 * :RPM)
			)
		),
		Set Property(
			"Predicting",
			{:Specific Power, Creator( "Neural" ), Std Dev( 0.225420351211502 )}
		),
		Set Property( "Expand Intermediates", 1 ),
		Set Property(
			"Response Limits",
			{Goal( Minimize ), Importance( 1 ), Show Limits( 0 )}
		),
		Set Selected
	)
);
LearningSigma
Level II

Re: Pump variable modeling

Hello ih, 

The pump speeds are not continuously variable, they are discreet levels, each will have its own power and flow, and 2 or 3 speeds must be chosen for a days run cycle.

 

Using the lowest RPM setting all the time is tempting, but there is a need to run devices such as salt generators, vacuum, solar heat, etc on most pools that introduces a need to have at least 1 of the settings at a minimum of 2500 RPM for at least 2-4 hours per day. It leads to a low, medium, high RPM scenario (or at least a low + high) to ensure enough volume and accessory capability.

 

I ran the scripts you provided, thanks for that. Should we be modeling this data to have 3 columns each for Speed 1, Speed 2, Speed 3, and then 3 each for the corresponding Power 1,2,3 and Flow 1,2,3, levels; the total flow and total power for the day are calculated based on sub-levels of power and flow? When I am seeing only 1 speed in the prediction profiler I am getting confused I guess.