tor  0.4.2.1-alpha-dev
laplace.h
Go to the documentation of this file.
1 /* Copyright (c) 2003, Roger Dingledine
2  * Copyright (c) 2004-2006, Roger Dingledine, Nick Mathewson.
3  * Copyright (c) 2007-2019, The Tor Project, Inc. */
4 /* See LICENSE for licensing information */
5 
12 #ifndef TOR_LAPLACE_H
13 #define TOR_LAPLACE_H
14 
15 #include "lib/cc/compat_compiler.h"
16 #include "lib/cc/torint.h"
17 
18 int64_t sample_laplace_distribution(double mu, double b, double p);
19 int64_t add_laplace_noise(int64_t signal, double random, double delta_f,
20  double epsilon);
21 
22 #endif /* !defined(TOR_LAPLACE_H) */
int64_t add_laplace_noise(int64_t signal, double random, double delta_f, double epsilon)
Definition: laplace.c:51
Integer definitions used throughout Tor.
Utility macros to handle different features and behavior in different compilers.
int64_t sample_laplace_distribution(double mu, double b, double p)
Definition: laplace.c:26