Charging and discharging device and method with privacy protection mechanism
The differential privacy Laplace mechanism handles electricity consumption data, which solves the problem that existing charging and discharging devices cannot protect users' electricity privacy, and achieves the effect of improving privacy and security.
Patent Information
- Application Number
- CN202410998139.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-07-24
- Publication Date
- 2024-11-12
AI Technical Summary
Existing charging and discharging devices cannot effectively protect users' power privacy. Attackers judge users' lifestyle habits through power usage behavior and charging data, resulting in a reduction in privacy and security.
The differential privacy Laplace mechanism is used to process the user's electricity consumption data, and the historical electricity consumption acquisition module, differential privacy protection module and charging and discharging module are added, random noise is added to calculate the privacy output power, and based on the actual electricity consumption. The relationship with the private output power determines the final power consumption, ensuring that the meter output is different from the real value but the statistical value is consistent.
It effectively improves the privacy and security of users' electricity use, prevents attackers from accurately judging users' electricity use behavior, and protects users' privacy.
Smart Images

Figure CN118944232A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of charging and discharging technology, and in particular to a charging and discharging device and method with a privacy protection mechanism. Background Art
[0002] For attackers, they often judge the user's life behavior through the electricity consumption behavior of ordinary users, and then launch attacks on users. For example, a user's home uses very little electricity from Wednesday to Friday (the electricity consumption only supports the daily electricity consumption of equipment such as refrigerators). After the attacker obtains the user's electricity consumption, it can be concluded that no one is at home from Wednesday to Friday; in addition, the attacker can also judge the user's use of private cars based on the amount of electricity charged by the home charging pile. For example, the charging amount on Monday and Tuesday is the sum of the other five days, which proves that the frequency of private car use on these two days is much higher than other time periods. The attacker can judge that the user has taken life behaviors such as traveling far away during this period. This judgment result provides the attacker with an effective attack time range, which greatly reduces the privacy security of the user's electricity use. Summary of the invention
[0003] The purpose of this application is to provide a charging and discharging device and method with a privacy protection mechanism, which can effectively improve the privacy security of users' electricity use.
[0004] To achieve the above objectives, this application provides the following solutions:
[0005] In a first aspect, the present application provides a charging and discharging device with a privacy protection mechanism, comprising: a historical power acquisition module, a differential privacy protection module, a charging and discharging module, and a power consumption output module connected in sequence;
[0006] The historical power acquisition module is used to acquire the historical power consumption of the user in a certain historical period;
[0007] The differential privacy protection module is used to:
[0008] Get the actual power consumption of the user per unit time;
[0009] The privacy output power is calculated using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time; the average power consumption per unit time is obtained based on the historical power consumption;
[0010] The charging and discharging module is used for:
[0011] Determine whether the battery meets the charging and discharging requirements based on the relationship between the private output power and the actual power consumption per unit time;
[0012] Determine the final power consumption based on whether the battery meets the charging and discharging requirements;
[0013] The power consumption output module is used to output the final power consumption.
[0014] Optionally, the actual power consumption within the unit time includes the actual power consumption per day or the actual power consumption per hour; the average power consumption within the unit time includes the average power consumption per day or the average power consumption per hour.
[0015] Optionally, the calculating of the privacy output power by using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time specifically includes:
[0016] According to the average power consumption per unit time and the actual power consumption f(D) per unit time, and the privacy output power A(D) is calculated using the differential privacy Laplace mechanism. in, The mean is 0 and the scale parameter is Laplace noise;
[0017] like The privacy output power A(D) is recorded and output, otherwise the differential privacy Laplace mechanism is used to recalculate the privacy output power A(D); where θ is the mean range threshold, 0<θ<1.
[0018] Optionally, determining whether the battery meets the charging and discharging requirements according to the relationship between the privacy output power and the actual power consumption per unit time specifically includes:
[0019] Whether the battery meets the charging and discharging requirements is determined based on the relationship between the privacy output power A(D) and the actual power consumption f(D) per unit time: if A(D)>f(D)+x, the battery cannot meet the charging requirements; if A(D)<f(D)-(Vx), the battery cannot meet the discharging requirements; where x is the remaining power of the battery; and V is the maximum power storage capacity of the battery.
[0020] Optionally, determining the final power consumption according to whether the battery meets the charging and discharging requirements specifically includes:
[0021] If the battery cannot meet the charging demand, then let A(D) = f(D) + x, and the privacy output power calculated in the next time period must be less than or equal to the actual power consumption in the next time period;
[0022] If the battery cannot meet the discharge demand, then set A(D) = f(D) - (Vx), and the privacy output power calculated in the next time period must be greater than or equal to the actual power consumption in the next time period.
[0023] In a second aspect, the present application provides a charging and discharging method with a privacy protection mechanism, which is applied to the charging and discharging device with a privacy protection mechanism. The charging and discharging method with a privacy protection mechanism includes:
[0024] Obtain the user's historical electricity consumption in a certain historical period and the user's actual electricity consumption per unit time;
[0025] The privacy output power is calculated using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time; the average power consumption per unit time is obtained based on the historical power consumption;
[0026] Determine whether the battery meets the charging and discharging requirements based on the relationship between the private output power and the actual power consumption per unit time;
[0027] The final power consumption is determined and displayed based on whether the battery meets the charging and discharging requirements.
[0028] Optionally, the calculating of the privacy output power by using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time specifically includes:
[0029] According to the average power consumption D per unit time and the actual power consumption f(D) per unit time, the privacy output power A(D) is calculated using the differential privacy Laplace mechanism. in, The mean is 0 and the scale parameter is Laplace noise;
[0030] like The privacy output power A(D) is recorded and output, otherwise the differential privacy Laplace mechanism is used to recalculate the privacy output power A(D); where θ is the mean range threshold, 0<θ<1.
[0031] Optionally, determining whether the battery meets the charging and discharging requirements according to the relationship between the privacy output power and the actual power consumption per unit time specifically includes:
[0032] Whether the battery meets the charging and discharging requirements is determined based on the relationship between the privacy output power A(D) and the actual power consumption f(D) per unit time: if A(D)>f(D)+x, the battery cannot meet the charging requirements; if A(D)<f(D)-(Vx), the battery cannot meet the discharging requirements; where x is the remaining power of the battery; and V is the maximum power storage capacity of the battery.
[0033] Optionally, determining the final power consumption and outputting and displaying it according to whether the battery meets the charging and discharging requirements specifically includes:
[0034] If the battery cannot meet the charging demand, then let A(D) = f(D) + x, and the privacy output power calculated in the next time period must be less than or equal to the actual power consumption in the next time period;
[0035] If the battery cannot meet the discharge demand, then set A(D) = f(D) - (Vx), and the privacy output power calculated in the next time period must be greater than or equal to the actual power consumption in the next time period.
[0036] According to the specific embodiments provided in this application, this application discloses the following technical effects:
[0037] The present application provides a charging and discharging device and method with a privacy protection mechanism. After obtaining the historical electricity consumption of a user in a certain historical period and calculating the average electricity consumption per unit time, a differential privacy Laplace mechanism is used to add random noise that satisfies the Laplace probability distribution to the actual electricity consumption per unit time for a single time, so as to achieve the purpose of privacy protection; then, the privacy output electricity is determined according to the average electricity consumption per unit time and the actual electricity consumption per unit time after adding the random noise, and the final electricity consumption is determined and output according to the relationship between the privacy output electricity and the actual electricity consumption, so that the output displayed by the meter is different from the true value, but the statistical value is consistent, thereby effectively improving the privacy security of the user's electricity consumption. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0039] Figure 1 A schematic diagram of the structure of a charging and discharging device with a privacy protection mechanism provided in this application;
[0040] Figure 2 Schematic diagram of the application environment of the charging and discharging device with a privacy protection mechanism provided in this application. DETAILED DESCRIPTION
[0041] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.
[0042] In order to make the above-mentioned objects, features and advantages of the present application more obvious and easy to understand, the present application is further described in detail below in conjunction with the accompanying drawings and specific implementation methods.
[0043] The charging and discharging device and method with a privacy protection mechanism in this application is intended to set up a privacy protection mechanism so that the charging and discharging of the battery is consistent with privacy protection. Specifically, by using differential privacy technology to process the electric meter, the output displayed by the electric meter is different from the true value, but the statistical value is consistent. For example, the actual power usage is different from the displayed power usage, but the actual total power usage is consistent with the displayed total power usage. The specific implementation process is as follows.
[0044] like Figure 1 As shown, the charging and discharging device with a privacy protection mechanism disclosed in the present application includes a historical power acquisition module, a differential privacy protection module, a charging and discharging module, and a power consumption output module which are connected in sequence.
[0045] Among them, the historical electricity acquisition module is mainly used to obtain the historical electricity consumption of users in a certain historical period, judge the user's electricity consumption statistics, and provide support for subsequent differential privacy protection.
[0046] Specifically, by obtaining the user's historical electricity consumption behavior in a certain historical period (such as the electricity consumption in the previous month or the previous few weeks), that is, obtaining the user's historical electricity consumption in a certain historical period, the user's average electricity consumption per unit time is calculated, which is recorded as The unit time may be daily or hourly, etc., so that the subsequent differential privacy protection module can calculate according to the average power consumption in the unit time and the actual power consumption of the user in the unit time, and add random noise that satisfies the Laplace probability distribution.
[0047] The differential privacy protection module is mainly used to add random noise that satisfies the Laplace probability distribution to the user's actual electricity consumption per unit time to achieve the purpose of privacy protection.
[0048] Specifically, the differential privacy protection module first obtains the actual power consumption f(D) of the user per unit time, and then calculates the average power consumption per unit time. And the actual power consumption f(D) in the unit time, the differential privacy Laplace mechanism (referred to as Laplace mechanism) is used to calculate the actual power consumption of the user per day (or per hour, etc.):
[0049]
[0050] Among them, A(D) is the output power after Laplace mechanism processing, that is, the privacy output power; The mean is 0 and the scale parameter is Laplace noise, then Satisfies ε-differential privacy.
[0051] Let θ be the mean range threshold and 0<θ<1, if The A(D) value is recorded, otherwise the Laplace mechanism is reused to add Laplace noise to the actual power consumption per unit time and calculate the privacy output power.
[0052] In order to make the privacy output power after adding Laplace noise within the range as much as possible, the value of ε should not be too small. If the value of ε is too small, the added Laplace noise will be too large.
[0053] The charging and discharging module is mainly used to process the user's actual power consumption per unit time according to the results of the differential privacy protection module, and use the battery to charge and discharge so that the required output power is consistent with the results of the differential privacy protection module.
[0054] The charge and discharge module first determines whether the battery meets the charge and discharge requirements based on the relationship between the privacy output power and the actual power consumption, and then determines the final power consumption based on whether the battery meets the charge and discharge requirements, as follows:
[0055] If the battery cannot meet the charging demand, that is, A(D)>f(D)+x, then A'(D)=f(D)+x, and the privacy output power calculated in the next time period must not be greater than the actual power consumption in the next time period, where x is the remaining power of the battery and A'(D) is the final power consumption.
[0056] If the battery cannot meet the discharge demand, that is, A(D)<f(D)-(Vx), then A'(D)=f(D)-(Vx), and the privacy output power calculated in the next time period must not be less than the actual power consumption in the next time period, where V is the maximum storage capacity of the battery.
[0057] The power consumption output module is used to output the final power consumption of the user according to the results processed by the charging and discharging module. Specifically, the power consumption output module uses A'(D) to output the final power consumption of the user per unit time according to the calculations of the above three modules; and sends the user's actual power consumption f(D) to the historical power consumption acquisition module for subsequent calculations.
[0058] like Figure 2 As shown, users use electricity generated by power plants and utilize the differential privacy charging and discharging mechanism of charging and discharging devices with privacy protection mechanisms to effectively prevent attacks from attackers, making it impossible for attackers to accurately know the user's electricity consumption, and thus unable to judge the user's electricity consumption behavior and attack the user.
[0059] In summary, the historical power acquisition module in the charging and discharging device with a privacy protection mechanism in the present application can effectively ensure that the final output power is close to the actual power used by the user, and can hide the actual power used by the user without too much error in the statistical value. The differential privacy protection module and the charging and discharging module use the differential privacy mechanism and the chargeable and dischargeable battery equipment to set up a privacy protection mechanism similar to differential privacy. While adding Laplace noise to the data to satisfy ε-differential privacy, the actual battery capacity and current power are taken into account to improve the privacy protection mechanism. Therefore, the charging and discharging device with a privacy protection mechanism in the present application can effectively improve the privacy security of the user's electricity use.
[0060] The present application also provides a charging and discharging method with a privacy protection mechanism, which is applied to the charging and discharging device with a privacy protection mechanism. The charging and discharging method with a privacy protection mechanism includes:
[0061] Obtain the user's historical electricity consumption in a certain historical period and the user's actual electricity consumption per unit time.
[0062] According to the average power consumption per unit time and the actual power consumption per unit time, the privacy output power is calculated using the differential privacy Laplace mechanism; the average power consumption per unit time is obtained based on the historical power consumption.
[0063] Whether the battery meets the charging and discharging requirements is determined based on the relationship between the private output power and the actual power consumption per unit time.
[0064] The final power consumption is determined and displayed based on whether the battery meets the charging and discharging requirements.
[0065] As a specific embodiment, the privacy output power is calculated using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time, specifically including:
[0066] According to the average power consumption per unit time and the actual power consumption f(D) per unit time, and the privacy output power A(D) is calculated using the differential privacy Laplace mechanism. in, The mean is 0 and the scale parameter is Laplace noise.
[0067] like The privacy output power A(D) is recorded and output, otherwise the differential privacy Laplace mechanism is used to recalculate the privacy output power A(D); where θ is the mean range threshold, 0<θ<1.
[0068] As a specific embodiment, determining whether the battery meets the charging and discharging requirements based on the relationship between the privacy output power and the actual power consumption per unit time specifically includes:
[0069] Whether the battery meets the charging and discharging requirements is determined based on the relationship between the privacy output power A(D) and the actual power consumption f(D) per unit time: if A(D)>f(D)+x, the battery cannot meet the charging requirements; if A(D)<f(D)-(Vx), the battery cannot meet the discharging requirements; where x is the remaining power of the battery; and V is the maximum power storage capacity of the battery.
[0070] As a specific embodiment, determining the final power consumption and outputting and displaying it according to whether the battery meets the charging and discharging requirements specifically includes:
[0071] If the battery cannot meet the charging demand, then A(D)=f(D)+x is set, and the privacy output power calculated in the next time period must be less than or equal to the actual power consumption in the next time period.
[0072] If the battery cannot meet the discharge demand, then set A(D) = f(D) - (Vx), and the privacy output power calculated in the next time period must be greater than or equal to the actual power consumption in the next time period.
[0073] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0074] This article uses specific examples to illustrate the principles and implementation methods of this application. The description of the above embodiments is only used to help understand the method and core ideas of this application. At the same time, for those skilled in the art, according to the ideas of this application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as limiting this application.
Claims
1. A charging and discharging device with a privacy protection mechanism, characterized in that: include: A historical power acquisition module, a differential privacy protection module, a charging and discharging module, and a power consumption output module connected in sequence; The historical power acquisition module is used to acquire the historical power consumption of the user in a certain historical period; The differential privacy protection module is used to: Get the actual power consumption of the user per unit time; The privacy output power is calculated using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time; the average power consumption per unit time is obtained based on the historical power consumption; The charging and discharging module is used for: Determine whether the battery meets the charging and discharging requirements based on the relationship between the private output power and the actual power consumption per unit time; Determine the final power consumption based on whether the battery meets the charging and discharging requirements; The power consumption output module is used to output the final power consumption.
2. The charging and discharging device with a privacy protection mechanism according to claim 1, characterized in that: The actual power consumption within the unit time includes the actual power consumption per day or the actual power consumption per hour; the average power consumption within the unit time includes the average power consumption per day or the average power consumption per hour.
3. The charging and discharging device with a privacy protection mechanism according to claim 1, characterized in that: The privacy output power is calculated using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time, specifically including: According to the average power consumption per unit time and the actual power consumption f(D) per unit time, and the privacy output power A(D) is calculated using the differential privacy Laplace mechanism. in, The mean is 0 and the scale parameter is Laplace noise; like The privacy output power A(D) is recorded and output, otherwise the differential privacy Laplace mechanism is used to recalculate the privacy output power A(D); where θ is the mean range threshold, 0<θ<1.
4. The charging and discharging device with a privacy protection mechanism according to claim 3, characterized in that: The determining whether the battery meets the charging and discharging requirements according to the relationship between the privacy output power and the actual power consumption per unit time specifically includes: Whether the battery meets the charging and discharging requirements is determined based on the relationship between the privacy output power A(D) and the actual power consumption f(D) per unit time: if A(D)>f(D)+x, the battery cannot meet the charging requirements; if A(D)<f(D)-(Vx), the battery cannot meet the discharging requirements; where x is the remaining power of the battery; and V is the maximum power storage capacity of the battery.
5. The charging and discharging device with a privacy protection mechanism according to claim 4, characterized in that: The final power consumption is determined according to whether the battery meets the charging and discharging requirements, specifically including: If the battery cannot meet the charging demand, then let A(D) = f(D) + x, and the privacy output power calculated in the next time period must be less than or equal to the actual power consumption in the next time period; If the battery cannot meet the discharge demand, then set A(D) = f(D) - (Vx), and the privacy output power calculated in the next time period must be greater than or equal to the actual power consumption in the next time period.
6. A charging and discharging method with a privacy protection mechanism, applied to the charging and discharging device with a privacy protection mechanism as claimed in any one of claims 1 to 5, characterized in that: The charging and discharging method with a privacy protection mechanism includes: Obtain the user's historical electricity consumption in a certain historical period and the user's actual electricity consumption per unit time; The privacy output power is calculated using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time; the average power consumption per unit time is obtained based on the historical power consumption; Determine whether the battery meets the charging and discharging requirements based on the relationship between the private output power and the actual power consumption per unit time; The final power consumption is determined and displayed based on whether the battery meets the charging and discharging requirements.
7. The charging and discharging method with a privacy protection mechanism according to claim 6, characterized in that: The privacy output power is calculated using the differential privacy Laplace mechanism according to the average power consumption per unit time and the actual power consumption per unit time, specifically including: According to the average power consumption per unit time and the actual power consumption f(D) per unit time, and the privacy output power A(D) is calculated using the differential privacy Laplace mechanism. in, The mean is 0 and the scale parameter is Laplace noise; like The privacy output power A(D) is recorded and output, otherwise the differential privacy Laplace mechanism is used to recalculate the privacy output power A(D); where θ is the mean range threshold, 0<θ<1.
8. The charging and discharging method with a privacy protection mechanism according to claim 7, characterized in that: The determining whether the battery meets the charging and discharging requirements according to the relationship between the privacy output power and the actual power consumption per unit time specifically includes: Whether the battery meets the charging and discharging requirements is determined based on the relationship between the privacy output power A(D) and the actual power consumption f(D) per unit time: if A(D)>f(D)+x, the battery cannot meet the charging requirements; if A(D)<f(D)-(Vx), the battery cannot meet the discharging requirements; where x is the remaining power of the battery; and V is the maximum power storage capacity of the battery.
9. The charging and discharging method with a privacy protection mechanism according to claim 8, characterized in that: The method of determining the final power consumption and outputting it for display according to whether the battery meets the charging and discharging requirements specifically includes: If the battery cannot meet the charging demand, then let A(D) = f(D) + x, and the privacy output power calculated in the next time period must be less than or equal to the actual power consumption in the next time period; If the battery cannot meet the discharge demand, then set A(D) = f(D) - (Vx), and the privacy output power calculated in the next time period must be greater than or equal to the actual power consumption in the next time period.
