question

Sri_vikas K avatar image
0 Likes"
Sri_vikas K asked Jeanette F commented

Mixer is not taking input

Hi,

In my model I have set port and amounts of mixers need to be added, but the fluid transfer is not taking from tank to mixer, I have checked weather the tank output is open. all output ports are open and fluid is not tarnsfering.

I have set the mixer recipe table like this:

1697700877600.png

What is the reason.

Thanks in advance.

FlexSim 23.1.3
fluid mixer
1697700877600.png (3.1 KiB)
· 1
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Jeanette F avatar image Jeanette F ♦♦ commented ·

Hi @Sri_vikas K, was Jason Lightfoot's answer helpful? If so, please click the "Accept" button at the bottom of their answer. Or if you still have questions, add a comment and we'll continue the conversation.

If we haven't heard back from you within 3 business days we'll auto-accept an answer, but you can always comment back to reopen your question.

0 Likes 0 ·

1 Answer

Jason Lightfoot avatar image
0 Likes"
Jason Lightfoot answered Sri_vikas K edited

This seems malformed to me - I'd expect a port amount to be unique for a given step.

· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Sri_vikas K avatar image Sri_vikas K commented ·
Thank, yes! You are right. I will work on making repeated port numbers to zero.
0 Likes 0 ·
Sri_vikas K avatar image Sri_vikas K commented ·

Hi @Jason Lightfoot

Using the code below I am setting the port column as well as amount columns in the mixer recipe table according to the recipe schedule. here actually I need to convert the repeated port numbers to zero and add converted zero row amount to the non-zero port.

example: In the table above 5th row has port number 3 and 8th row port number is also 3, it should be converted to zero and amount(2) in the 8th row should be added to amount in the row 5 (i.e., 2+2 =4).

/**Custom Code*/

Table recipeTable=getvarnode(Model.find("FluidMixer1"), "recipetable");

Table globRecipes=Table("RecipeTable");

Table globalports= Table("RecipePorts");

string newRecipe="Recipe2";

for (int n=globRecipes.numCols;n>0;n--){

string ingredient=globRecipes.getColHeader(n);

int row=recipeTable.getRowByKey(ingredient,1);

recipeTable[row]["Amount"]= globRecipes[newRecipe][n];

}



/**Custom Code*/

for (int n=globalports.numCols;n>0;n--){

string port=globalports.getColHeader(n);

int row=recipeTable.getRowByKey(port,1);

recipeTable[row]["Port"]= globalports[newRecipe][n];

}







Thanks in Advance

0 Likes 0 ·