/* Initialization */
#include "Sum_model.h"
#include "Sum_11mix.h"
#include "Sum_12jac.h"
#if defined(__cplusplus)
extern "C" {
#endif

void Sum_functionInitialEquations_0(DATA *data, threadData_t *threadData);


/*
 equation index: 1
 type: SIMPLE_ASSIGN
 y = sum1.k[1] * u + sum1.k[2] * u1
 */
void Sum_eqFunction_1(DATA *data, threadData_t *threadData)
{
  TRACE_PUSH
  const int equationIndexes[2] = {1,1};
  data->localData[0]->integerVars[2] /* y DISCRETE */ = ((modelica_integer)data->simulationInfo->integerParameter[0]) * ((modelica_integer)data->localData[0]->integerVars[0] /* u variable */) + ((modelica_integer)data->simulationInfo->integerParameter[1]) * ((modelica_integer)data->localData[0]->integerVars[1] /* u1 variable */);
  TRACE_POP
}
void Sum_functionInitialEquations_0(DATA *data, threadData_t *threadData)
{
  TRACE_PUSH
  Sum_eqFunction_1(data, threadData);
  TRACE_POP
}


int Sum_functionInitialEquations(DATA *data, threadData_t *threadData)
{
  TRACE_PUSH

  data->simulationInfo->discreteCall = 1;
  Sum_functionInitialEquations_0(data, threadData);
  data->simulationInfo->discreteCall = 0;
  
  TRACE_POP
  return 0;
}


int Sum_functionInitialEquations_lambda0(DATA *data, threadData_t *threadData)
{
  TRACE_PUSH

  data->simulationInfo->discreteCall = 1;
  data->simulationInfo->discreteCall = 0;
  
  TRACE_POP
  return 0;
}
int Sum_functionRemovedInitialEquations(DATA *data, threadData_t *threadData)
{
  TRACE_PUSH
  const int *equationIndexes = NULL;
  double res = 0.0;

  
  TRACE_POP
  return 0;
}


#if defined(__cplusplus)
}
#endif

