Here is some paid module and this may solve your problem
                        - Imagine, you are manufacturing tables made to order. The 
possible width of those tables is from 40cm to 80cm and you find it 
rational to produce only even-number-width tables (42cm, 44cm, etc.)
- The Public (base template) price is $100
- Each 1cm adds $2.15 to this price.
- Besides, you find it profitable to have a 0.03% increase for each cm, and 1% for each unit disregarding the width
- Thus, you go to the product template "Table" and press the button "Num Attributes" (the tab "Variants")
- In the field "Select or create new attribute" you choose 
"Width". You enter '' cm" in the "Comment" field. You have the line in 
the configuration table: 40 â 80 â 2 - Formula
- The formula for Price Extra =  Attribute Value * 2.15 + 0
- The formula for Price Multiplier =  Attribute Value * 0.03 + 1
-  You press "Generate" and have 
the list of all feasible tables. The price for 54cm table, for example, 
is $218.72 = 100 * (54*0.03+1) + 54*2.15
https://apps.odoo.com/apps/modules/11.0/variants_bridge_pricing_numerical/
also see below module too
https://apps.odoo.com/apps/modules/9.0/variant_price_extra/
            
                This module allows you to set and manage extra price for each product's variant separately.
            
            
                You can simply set the extra price to be applied on a 
product's variant, regardless of it's attribute and attribute value. 
            
If you find this helpful vote for me