[Simnibs-discuss] Question about BCs and getting nodal potentials
Axel Thielscher
axelt at drcmr.dk
Tue Dec 21 19:50:03 CET 2021
Hi Hassan,
please see below.
On 12/21/2021 2:26 PM, Hassan Yazdanian wrote:
>
> Hello,
>
> I am trying y to compare the result obtained by SimNIBS with that one
> calculated by FEniCS (https://fenicsproject.org/) for a tDCS
> simulation. For this purpose, I have imported .msh file generated by a
> SimNIBS simulation into FEniCS. I have used the spherical model
> provided in SimNIBS dataset. Now, I have two questions:
>
> 1-How can I get the electrical potentials of nodes and corresponding
> nodal coordinates? In earlier versions of SimNIBS, I used “v =
> fem.tdcs_getdp”. I was wondering if there is a similar command in
> SimNIBS 3.2.
>
You can add a 'v' to the 'fields' attribute when defining the simulation:
https://simnibs.github.io/simnibs/build/html/documentation/sim_struct/session.html
The potential will then be added as node_data to the results mesh. The
nodal positions are stored under the "nodes" parameter:
https://simnibs.github.io/simnibs/build/html/documentation/python_lib/auto/simnibs.Msh.html#simnibs.Msh
> 2-About applying boundary condition, as I understood, SimNIBS uses a
> constant potential on electrodes (Say -1 on Cathode and 0 on Anode).
> After solving the FEM system of equations, then potentials are scaled
> to reach the given current set for electrodes ( I mean we know the
> potential on 2101 and 1501 surfaces, both side of Anode, and we know
> the conductivity of the electrode, 29.4 S/m, then we can determine the
> current passing through the electrode). Am I right?
>
Yes, that's correct.
Merry Christmas and a good start into the new year to you, too!
Best,
Axel
> Merry Christmas and Happy new year in advance!
>
> Best wishes,
>
> -Hassan
>
>
> _______________________________________________
> Simnibs-discuss mailing list
> Simnibs-discuss at drcmr.dk
> https://mailman.drcmr.dk/mailman/listinfo/simnibs-discuss
--
Dr. Axel Thielscher
Professor of Neurophysics and Neuroimaging
Danish Research Center for Magnetic Resonance
Copenhagen University Hospital Hvidovre
DK-2650 Hvidovre, Denmark
www.drcmr.dk
&
Department of Health Technology
Technical University of Denmark
DK-2800 Kgs. Lyngby
http://www.healthtech.dtu.dk/
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mailman.drcmr.dk/pipermail/simnibs-discuss/attachments/20211221/678af91e/attachment.html>
More information about the Simnibs-discuss
mailing list