Optimization using STAN using Simplex

Hi,
I am trying to fit a model to optimize the response variable Y where
Y = \beta_0 + X_1\beta_1 + X_2\beta_2 such that X_1\beta _1 + X_2\beta_2 \leq 0.7 .

I was wondering, how to modify the below stan code or use simplex to solve the above problem.


data{
  int N;  
  int Np;
  int J;
  vector[Np] x;                             
}

parameters {
  vector<lower=0> [N] beta0;
  vector<lower=0> [N] beta1;
  vector<lower=0> [N] beta2;
  vector<lower=0, upper=0.7>[N] k_constant;
  simplex[Np] alpha[N];

}

transformed parameters {
  
  vector[Np] y_beta[N];
  for(i in 1:N) {
    y_beta[i,1] = beta1[i]*x[1];
    y_beta[i,2] = beta2[i]*x[2];
  
    y_beta[i] = k_constant[i] * alpha[i];   
} 
  
model {
  beta0 ~ normal(0,1);
  beta1 ~ normal(0,1);                     
  beta2 ~ normal(0,1); 

  y ~ normal(beta0 + beta1*x[1] + beta2*x[2], 1);
  
}
****

This defines a lower bound too, your definition not. If you want both, just use inv_logit and scale by 0.7.