p = path->pins->data[j];
if (j0 < 0) {
- if (p->lid == vip->lid)
+ if (!(j & 0x1) && p->lid == vip->lid)
j0 = j;
else
continue;
scf_logw("flow vip: c%ldp%ld->a: %lg, fp0: c%ldp%ld->a: %lg, fp1: c%ldp%ld->a: %lg\n\n",
flow->vip->cid, flow->vip->id, flow->vip->a, fp0->cid, fp0->id, fp0->a, fp1->cid, fp1->id, fp1->a);
- double da = 0;
- double dja = 0;
+ double da;
+ double dja;
+
+ double v;
+ double jv;
double a = 0;
double ja = 0;
-
double Eta = 0.001;
int k = 0;
scf_loge("da: %lg, a: %lg\n", da, a);
- double dv = flow->vip->v;
- double djv = flow->vip->jv;
+ v = flow->vip->v;
+ jv = flow->vip->jv;
ret = __ses_flow_a_pos(f, flow, a, ja);
if (ret < 0)
return ret;
- dv = flow->vip->v - dv;
- djv = flow->vip->jv - djv;
+ double dv = flow->vip->v - v;
+ double djv = flow->vip->jv - jv;
- scf_logi("dv: %lg, ----------------\n", dv);
+ scf_logi("dv: %lg, v: %lg - %lg ----------------\n", dv, flow->vip->v, v);
ret = __ses_flow_v_neg(f, flow, dv, djv);
if (ret < 0)
printf("\n");
k++;
- } while (k < 20);
+ } while (k < 46);
- double v = p0->v - p1->v;
- double jv = p0->jv - p1->jv;
+ v = p0->v - p1->v;
+ jv = p0->jv - p1->jv;
scf_loge("bridge: %d, c%ldp%ld--c%ldp%ld, v: %lg, p0->v: %lg, p1->v: %lg, n_diodes: %d, p0->a: %lg, p1->a: %lg\n",
bridge->index, p0->cid, p0->id, p1->cid, p1->id, v, p0->v, p1->v, bridge->n_diodes, p0->a, p1->a);