ScfEpin* vip = flow->vip;
ScfEpin* p0;
ScfEpin* p;
+ ScfEline* el;
double tr = flow->pos_r;
double jtr = flow->pos_jr;
p->v -= v;
p->jv -= jv;
- f->elines[p->lid]->v = p->v;
- f->elines[p->lid]->jv = p->jv;
+ el = f->elines[p->lid];
+ el->v = p->v;
+ el->jv = p->jv;
- scf_logw("c%ldp%ld->v: %lg, r: %lg\n", p->cid, p->id, p->v, r);
+ scf_logw("c%ldp%ld->v: %lg, r: %lg, l%ld->v: %lg\n", p->cid, p->id, p->v, r, el->id, el->v);
break;
}
vip->v -= v;
vip->jv -= jv;
- f->elines[vip->lid]->v = vip->v;
- f->elines[vip->lid]->jv = vip->jv;
+ el = f->elines[vip->lid];
+ el->v = vip->v;
+ el->jv = vip->jv;
- scf_logw("c%ldp%ld->v: %lg, r: %lg\n", vip->cid, vip->id, vip->v, tr);
+ scf_logw("c%ldp%ld->v: %lg, r: %lg, l%ld->v: %lg\n", vip->cid, vip->id, vip->v, tr, el->id, el->v);
}
return 0;
ScfEpin* vip = flow->vip;
ScfEpin* p0;
ScfEpin* p;
+ ScfEline* el;
double tr = flow->neg_r;
double jtr = flow->neg_jr;
p->v += v;
p->jv += jv;
- f->elines[p->lid]->v = p->v;
- f->elines[p->lid]->jv = p->jv;
+ el = f->elines[p->lid];
+ el->v = p->v;
+ el->jv = p->jv;
- scf_loge("c%ldp%ld->v: %lg, r: %lg, %lg\n", p->cid, p->id, p->v, r, p->sr);
+ scf_logw("c%ldp%ld->v: %lg, r: %lg, l%ld->v: %lg\n", p->cid, p->id, p->v, r, el->id, el->v);
}
assert(p0);
vip->v += v;
vip->jv += jv;
- f->elines[vip->lid]->v = vip->v;
- f->elines[vip->lid]->jv = vip->jv;
+ el = f->elines[vip->lid];
+ el->v = vip->v;
+ el->jv = vip->jv;
- scf_logw("c%ldp%ld->v: %lg + j%lg, r: %lg + j%lg\n", vip->cid, vip->id, vip->v, vip->jv, tr, jtr);
+ scf_logw("c%ldp%ld->v: %lg, r: %lg, l%ld->v: %lg\n", vip->cid, vip->id, vip->v, tr, el->id, el->v);
}
}
k++;
} while (k < 3);
- scf_logw("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",
+ 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);
return 0;