Veda2.0 Released!


Help with constructing user constraint (ZEV)
#1
Hi,
I am trying to represent California's Zero Emission Vehicle (ZEV) mandate in a user constraint but I'm running into trouble. 

I thought the representation is relatively straightforward but I'm having trouble setting it up as a VEDA scenario file.

Each ZEV vehicle type has a weighting factor (a) that is multiplied by the number of vehicles sold in a given year to give more or less "credit" to that vehicle.  Full battery electric vehicles and fuel cells have greater weights than a plug in hybrid (which isn't a true ZEV).

The sum of these weighted ZEV sales has to be greater than or equal to a given percentage of total car sales.

The challenge I'm having is that I'm entering the weighting coefficients (a) for each individual ZEV vehicles as UC_NCAP values but I am also trying to sum across all vehicle sold (not just ZEVs), which has another coefficient (the ZEV Target %). 

Below is what I put together:
The first set of rows with "TCAR*" is meant to represent the 2nd half of the left side of the equation, the UC_NCAP values are the ZEV target percentages for each year.
All the subsequent rows are meant to just give the weighting factors for each type of vehicle.
 
but I know it's not quite right because when I view the UC Master, I can see that I have not differentiated between the TCAR* values (i.e. all the vehicles I'm trying to sum across) and the individual vehicle vehicle types (e.g. TCARELC1, TCARELC2, TCARFCH2, etc) and the coefficients that I'm specifying for the weighting factors is being written in the same spot as the Target percentage.

Hopefully this question is somewhat clear.  Thanks in advance for any help that you can provide.

Chris














~UC_Sets: R_E: AllRegions












~UC_Sets: T_E:





















~UC_T



UC_N UC_ATTR~LHS Pset_Set Pset_PN Pset_CO Cset_SET Cset_CN Attribute Year LimType UC_NCAP UC_RHSRTS UC_RHSRTS~0 UC_Desc
\I:  ZEV Mandate Overall Constraint
UC_ZEV_TZEV_to_2025 NCAP
TCAR*



2012 LO -0.03 0 15



TCAR*



2013
-0.03





TCAR*



2014
-0.03





TCAR*



2015
-0.06





TCAR*



2016
-0.06





TCAR*



2017
-0.06





TCAR*



2018
-0.05





TCAR*



2019
-0.07





TCAR*



2020
-0.1





TCAR*



2021
-0.12





TCAR*



2022
-0.15





TCAR*



2023
-0.17





TCAR*



2024
-0.2





TCAR*



2025
-0.22





TCARELC1



2012
3





TCARELC1



2017
3





TCARELC1



2018
1.5





TCARELC1



2025
1.5





TCARELC2



2012
4





TCARELC2



2017
4





TCARELC2



2018
2.5





TCARELC2



2025
2.5





TCARFCH2



2012
9





TCARFCH2



2017
9





TCARFCH2



2018
4





TCARFCH2



2025
4





TCAR*PHEV10



2012
1.1





TCAR*PHEV10



2017
1.1





TCAR*PHEV10



2018
0.4





TCAR*PHEV10



2025
0.4





TCAR*PHEV30



2012
2.0





TCAR*PHEV30



2017
2.0





TCAR*PHEV30



2018
0.6





TCAR*PHEV30



2025
0.6





TCAR*PHEV40



2012
2.5





TCAR*PHEV40



2017
2.5





TCAR*PHEV40



2018
0.7





TCAR*PHEV40



2025
0.7





TCAR*PHEV60



2012
3.0





TCAR*PHEV60



2017
3.0





TCAR*PHEV60



2018
0.9





TCAR*PHEV60



2025
0.9


Reply
#2
what you have is equivalent to:

(weights x sales of targeted cars) >= target x sales of non-targeted cars

here is what it should be:

(weights x sales of targeted cars) >= target x (sales of targeted cars + sales of non-targeted cars)

rearranging, you will get new coeff for the targeted cars as (weight - target). you can leave the first part unchanged (TCAR*) as the values for targeted cars will get overwritten anyway.

hope the answer is somewhat clear.
Reply
#3
 In this case it might be easier and more transparent to make use both sides, LHS and RHS, putting the target coefficients on the RHS and the weights on the LHS.  Then use UC_ATTR(NCAP,SYNC) on the RHS to activate both sides in the equation. 
Reply
#4
That's a great idea Antti! So, any share UC could be defined more transparently like this, right?

I have been using the RHS only for GROWTH cases.

Thanks!
Reply
#5

AKanudia Wrote:That's a great idea Antti! So, any share UC could be defined more transparently like this, right?

Right. Just define UC_ATTR~RHS with <type>,SYNC (here <type> was NCAP) and you will get both sides active.

Reply
#6
Hi Antti and Amit,

Thanks so much for the input on the formulation. 
I understand Amit's point well enough to implement it in the way that he's suggested. 
I understand the concept of Antti's reply, but not the details well enough to implement it. 

I think that I'm supposed to add a column with:
UC_ATTR~RHS
NCAP, SYNC

and specify two columns for UC_NCAP
UC_NCAP~LHS UC_NCAP~RHS

and then just move the Target values to the RHS (and changing the sign)

Is that correct?

thanks!

Chris
UC_N UC_ATTR~LHS UC_ATTR~RHS Pset_Set Pset_PN Pset_CO Cset_SET Cset_CN Attribute Year LimType UC_NCAP~LHS UC_NCAP~RHS UC_RHSRTS UC_RHSRTS~0
\I:  ZEV Mandate Overall Constraint
UC_ZEV_TZEV_to_2025 NCAP NCAP, SYNC
TCAR*



2012 LO
 0.03 0 15




TCAR*



2013

 0.03





TCAR*



2014

 0.03





TCAR*



2015

 0.06





TCAR*



2016

 0.06





TCAR*



2017

 0.06





TCAR*



2018

 0.05





TCAR*



2019

 0.07





TCAR*



2020

 0.10





TCAR*



2021

 0.12





TCAR*



2022

 0.15





TCAR*



2023

 0.17





TCAR*



2024

 0.20





TCAR*



2025

 0.22





TCARELC1



2012
3






TCARELC1



2017
3






TCARELC1



2018
1.5






TCARELC1



2025
1.5






TCARELC2



2012
4






TCARELC2



2017
4






TCARELC2



2018
2.5






TCARELC2



2025
2.5






TCARFCH2



2012
9






TCARFCH2



2017
9






TCARFCH2



2018
4






TCARFCH2



2025
4



Reply
#7
Yes, correct.   
Reply
#8
Antti and Amit

many thanks for your explanations and suggestions.  I have gotten the constraint working. 

Chris
Reply


Possibly Related Threads…
Thread Author Replies Views Last Post
  Tradeoff for user-defined objective function Sandro_Luh 27 16,580 14-02-2023, 03:50 PM
Last Post: Antti-L
  user constraint on subset of emissions Stefan 2 2,833 10-11-2021, 08:26 PM
Last Post: Stefan
  DACCS Emissions Constraint not working UKTM User 10 9,425 07-10-2021, 03:30 PM
Last Post: UKTM User
  Functionality of the RPS constraint xavier 3 4,370 02-05-2021, 07:07 PM
Last Post: Antti-L
  User constraint for minimum storage activity Anjali 4 4,623 15-01-2021, 07:38 PM
Last Post: Anjali
  Issue with constraint: Error Code 172 NeilGrant 5 7,415 28-05-2020, 02:08 PM
Last Post: NeilGrant
  Aggregated constraint in a VT_file? Pernille.S 3 5,618 19-09-2019, 01:46 PM
Last Post: Antti-L
  Constraint on LUMPINV kristofferand 1 4,115 03-09-2019, 04:39 PM
Last Post: Antti-L
  Minimum Utilization Constraint on activity Giulia Realmonte 5 10,209 23-04-2019, 01:53 PM
Last Post: NeilGrant
  Help with user constraint newbie1 12 18,915 02-06-2018, 07:07 PM
Last Post: newbie1

Forum Jump:


Users browsing this thread: 2 Guest(s)