# Write and run a complete JoSIM circuit netlist

Start with a small circuit containing sources, components, analysis and output requests. Save a complete plain-text deck, run it to a separate result file and check quantities against a simple reference.

## Compatibility

2.9.0 release target; bounded Windows RC CLI evidence

Published guidance with release-applicability limits. Confirm package applicability before following this guide.

[Download RC circuit (ZIP)](/_functions/kbExample?name=rc-basic.zip)

Includes: rc_basic.cir, README.txt.

## Before starting

Use the intended licensed JoSIM®-Pro installation and a new writable working folder. Check its CLI version. This example was exercised on the recorded Windows 2.9 review CLI; final-package and other-platform checks remain open.

Save the circuit below as UTF-8 plain text named rc_basic.cir. Confirm the actual extension rather than a hidden .txt suffix. Node 0 is the reference; IN and OUT are node names. The initial * line is a comment.

## Create the complete circuit

.PARAM DRIVE=1m supplies the PWL source amplitude: 1 mV here. R1 is 50 ohms and C1 is 0.2 pF, so the RC time constant is 10 ps. The source rises from 0 to 1 mV between 10 and 20 ps and then stays constant.

The R and C lines provide the electrical network, .OPTION selects VOLTAGE/BDF for this example, .TRAN requests a 0.5 ps integration step to 100 ps, and .PRINT requests two voltages and the R1 current. .END terminates the deck.

A Josephson circuit additionally needs the appropriate B instance and matching model card/library. Use the model guide for its parameters and scaling; this linear RC example does not establish junction physics.

```text
* RC response: 50 ohm, 0.2 pF, 10 ps time constant
.PARAM DRIVE=1m
V1 IN 0 PWL(0 0 10p 0 20p DRIVE 100p DRIVE)
R1 IN OUT 50
C1 OUT 0 0.2p
.OPTION ANALYSIS=VOLTAGE INTEGRATION=BDF
.TRAN 0.5p 100p
.PRINT V(IN) V(OUT) I(R1)
.END
```

## Run and inspect the saved deck

1. Run the command below from the working folder. If the executable is not on PATH, use its actual installed path as described in the CLI guide.
2. Read the first diagnostic and job status. Confirm rc_basic.csv is newly created, then inspect its headers and time span.
3. Keep seconds, volts and amperes attached to the exported columns. Check the response before introducing additional devices or models.

```text
josim-pro-cli -o rc_basic.csv rc_basic.cir
```

## Recognise success

The checked file has time, V(IN), V(OUT) and I(R1) columns, 201 finite samples and a 0–100 ps span. The output charges toward 1 mV after the input ramp; the reference at 50 ps is approximately 0.96853 mV.

For an independent check, let A=1e-3 V, T=10e-12 s and tau=50*0.2e-12 s. During the ramp, with u=t-10e-12, Vout=(A/T)*(u-tau*(1-exp(-u/tau))). After 20 ps, Vout=A*(1-(tau/T)*(1-exp(-T/tau))*exp(-(t-20e-12)/tau)). Before the ramp Vout=0.

The checked 0.5 ps run stayed within 0.5% of the 1 mV drive when compared with that ideal reference. The refinement guide makes the time-step effect explicit; this local criterion does not establish a production model tolerance.

## If parsing or simulation fails

Use the exact diagnostic to check the saved filename, statement spelling, node connections, required model/library and complete .TRAN/.PRINT/.END lines. The analysis uses the saved file, not unsaved editor text.

Write output to a separate path and use a new result name after a failed attempt. For missing dependencies follow the include-recovery guide; for a matrix/topology diagnostic reduce to a complete small circuit before tuning the solver.

## Sources and verification details

Recorded inputs/builds only. Complete walkthrough and final-package acceptance remain separate.

- VAL-014: JoSIM-Pro 2.9.0 installed Windows review CLI. Complete linear RC circuit, included parameterised cell, include recovery, fixed-step refinement, nine scalar forms and measurement failure/recovery Handwritten RC examples and their declared analytic criteria only. No Josephson-device, adaptive/noisy, GUI, other-platform or final-release qualification. CLI loaded-library path was not observed.


- josim-pro:docs/manual_source/sections/syntax.tex: Netlist anatomy, resistor/capacitor, PWL voltage source, transient and output statements
- josim-pro:docs/manual_source/sections/usage.tex: CLI input/output and versioned execution contract
- validation:josim-authoring-windows-20261103: VAL-014: exact RC examples, independent reference checks and recovery

- The documented RC files match the checked input content. All new outputs were written to fresh paths.
- Final distributed 2.9 package, other platforms and GUI workflows remain pending. Example-specific analytic allowances are not universal solver tolerances.

## Related guides

- [Run JoSIM®-Pro from the command line and save numerical output](/knowledge-base/josim-cli-output)
- [Run the intended saved netlist and recognise stale results](/knowledge-base/josim-run-current-source)
- [A junction model is missing or behaves like the wrong model](/knowledge-base/josim-model-syntax)
- [Reuse a parameterised subcircuit from an included library](/knowledge-base/josim-hierarchical-design)
- [Choose and refine simulation and output time steps](/knowledge-base/josim-transient-timestep)
- [Find declarations, references and source locations](/knowledge-base/josim-editor-navigation)
- [Use completion, linked snippets and live diagnostics](/knowledge-base/josim-editor-completion)
- [Use dependent sources and verify their control direction](/knowledge-base/josim-controlled-sources)
