00001
00012 #ifndef PREPOSTDEPENDENTDELAY_H_
00013 #define PREPOSTDEPENDENTDELAY_H_
00014
00015 #include "ConnObjectValueGenerator.h"
00016 #include "RandomDistribution.h"
00017
00018
00019 #if !defined(max)
00020 #define max(A, B) ((A) > (B) ? (A) : (B))
00021 #endif
00022 #if !defined(min)
00023 #define min(A, B) ((A) < (B) ? (A) : (B))
00024 #endif
00025
00026
00027
00028
00029
00030
00031 class DelayCond: public SpatialConnObjectValueGenerator
00032 {
00033 public:
00034 DelayCond(double v_mean, double v_SH, double v_min, double v_max);
00035
00036 virtual ~DelayCond();
00037
00038 virtual double generate(size_t src_idx, size_t dst_idx, RandomEngine *rnd);
00039
00040 virtual ConnObjectValueGenerator* clone(void) const;
00041
00042 protected:
00043 double v_mean, v_SH, v_min, v_max;
00044
00045 BndNormalDistribution v_dist;
00046 };
00047
00048
00049
00050
00051
00052
00053 class DelayCondAndSyn : public SpatialConnObjectValueGenerator
00054 {
00055 public:
00056 DelayCondAndSyn(double v_mean, double v_SH, double v_min, double v_max,
00057 double d_mean, double d_SH, double d_min, double d_max);
00058
00059 virtual ~DelayCondAndSyn();
00060
00061 virtual double generate(size_t src_idx, size_t dst_idx, RandomEngine *rnd);
00062
00063 virtual ConnObjectValueGenerator* clone(void) const;
00064
00065 protected:
00066 double v_mean, v_SH, v_min, v_max;
00067 double d_mean, d_SH, d_min, d_max;
00068
00069 BndNormalDistribution v_dist;
00070 BndNormalDistribution delay_dist;
00071 };
00072
00073
00074
00075
00076
00077
00078
00079
00080 class LateralDelayCondAndSyn : public SpatialConnObjectValueGenerator
00081 {
00082 public:
00083 LateralDelayCondAndSyn(double v_mean, double v_SH, double v_min, double v_max,
00084 double d_mean, double d_SH, double d_min, double d_max,
00085 bool toroid=false, double toroid_off=0.0, double z_scale=1.0,
00086 double src_scale=1.0, double dst_scale=1.0,
00087 double src_center_x=0.0, double src_center_y=0.0,
00088 double dst_center_x=0.0, double dst_center_y=0.0,
00089 double src_shape_x=1.0, double src_shape_y=1.0,
00090 double dst_shape_x=1.0, double dst_shape_y=1.0);
00091
00092 virtual ~LateralDelayCondAndSyn();
00093
00094 virtual double generate(size_t src_idx, size_t dst_idx, RandomEngine *rnd);
00095
00096 virtual ConnObjectValueGenerator* clone(void) const;
00097
00098 protected:
00099 double v_mean, v_SH, v_min, v_max;
00100 double d_mean, d_SH, d_min, d_max;
00101
00102 bool m_toroid;
00103 bool m_toroid_off;
00104
00105 double m_z_scale;
00106 double m_src_scale;
00107 double m_dst_scale;
00108
00109 double m_src_center_x;
00110 double m_src_center_y;
00111 double m_dst_center_x;
00112 double m_dst_center_y;
00113
00114 double m_src_shape_x;
00115 double m_src_shape_y;
00116 double m_dst_shape_x;
00117 double m_dst_shape_y;
00118
00119 double min_dx, min_dy, max_dx, max_dy;
00120 double min_sx, min_sy, max_sx, max_sy;
00121
00122 BndNormalDistribution v_dist;
00123 BndNormalDistribution delay_dist;
00124 };
00125
00126 #endif //PREPOSTDEPENDENTDELAY_H_