Use formulas with lookups

Use formulas with lookups

murmanator
Advocate Advocate
720 Views
4 Replies
Message 1 of 5

Use formulas with lookups

murmanator
Advocate
Advocate

Hello, In the attached block, I am attempting to fill in the PVCMAINDRAIN and PVCSKIMMER attributes based on the Filter Pump Suction Lookup table. The table works fine as it sits now however a bit of math needs to be done in order to get the values for the drain and skimmer PVC attributes.

 

You'll see where I have the FILTERPUMPGPM attribute being fed by the Filter Pump GPM Input parameter. In order to calculate the drain GPM we need to multiply by .5, and in order to get the skimmer GPM we multiply by .75. I have added attributes with formulas to get these GPM values. Now, the problem is getting these GPM values to feed into the lookup table somehow (if it's possible).

 

You'll also see where I attempted to add a second linear parameter with its actions chained to the Filter Pump Input one but that didnt work out as I couldnt get it to always be 1/2 the value of the input. I know how to get the stretch action to do this but I dont think that helps in this case. Is the only solution to add 2 lookups and do all the math prior to adding the data? Thats the only way I could think of, not being entirely fluent in lookups. Thank you

0 Likes
721 Views
4 Replies
Replies (4)
Message 2 of 5

murmanator
Advocate
Advocate

Well, I attempted to do the solution I mentioned at the end there and it will not work. The values are not right at the output. Somehow I need to get those drain and skimmer GPM values to feed into the lookup table.

0 Likes
Message 3 of 5

scooberu
Enthusiast
Enthusiast

I did not look at your drawing, but:

In the block editor, use the parameters manager to add custom properties to the block. All parameters do is show text. But custom properties can have formulae referencing other properties and can also be referenced by properties and parameters. they are called block placeholders in the field definition dialog box.

 

0 Likes
Message 4 of 5

murmanator
Advocate
Advocate

Thank you for the info. I am struggling with how to implement this to make my block work how I want. Im not sure about adding custom properties (isnt this just the linear parameters I have in there? Not sure what else I can add here.) I see the block placeholder but Im not sure how to use it to make the formula I want work. Can you perhaps give more direction on how to connect these things? Thanks you again.

0 Likes
Message 5 of 5

scooberu
Enthusiast
Enthusiast

It sounds like you are trying to place computed values into a table to be looked up....? If so, I don't think you will be successful.

But you can use block property values to compute other properties or attributes. To use them in an attribute:

In block definition, select the attribute, go to its default value, and insert a field. In the field, place a formula. 

In the formula, insert other fields. In the (nested) field(s), choose "object" , "block placeholder", then select the property you need.

NOTE: other ATTRIBUTES WILL NOT SHOW UP AS BLOCK PLACEHOLDERS, BUT BLOCK PROPERTIES WILL. That is what I was referring to in my first comment. 

 

0 Likes