Capacitor

Scicos Block
fr - eng

##
Electrical capacitor

### Contents

- Electrical capacitor
  - Description
  - Dialog box
  - Default properties
  - Interfacing function
  - Modelica model

### Description

A capacitor is an electrical component that can store energy in electrical circuits. The relationship between the voltage across a capacitor with capacitance and the current passing through it is given by the:

Capacitors can also be used to differentiate between high-frequency and low-frequency signals and this makes them useful in electronic filters. A capacitor has a hight impedence when a signal is low frequency signals.

### Dialog box

Set Capacitor block parameter |
C (F) | 0.01
Initial Voltage | 0

- C (F) : Type 'vec' of size 1. Capasitance
- Initial Voltage : Type 'vec' of size 1. Initial Voltage

### Default properties

- always active: no
- direct-feedthrough: yes
- zero-crossing: no
- mode: no
- number/sizes of inputs: 1 / 1
- number/sizes of outputs: 1 / 1
- number/sizes of activation inputs: 0 /
- number/sizes of activation outputs: 0 /
- continuous-time state: no
- discrete-time state: no
- name of modelica function: Capacitor

### Interfacing function

`Capacitor.sci`

### Modelica model

    class Capacitor
    	Pin p, n;
    	Real v;
    	parameter Real C "Capacitance";
    equation
    	C*der(v) = p.i;
    	v = p.v - n.v;
    	p.i = -n.i;
    end Capacitor;