/* Voltage drop across the myelin sheath of an myelinated axon, under a transverse electric field exposure */

/ * Step 1: voltage distributation inside the myelin sheath.*/

V1=-((2 (a^2) E0 S0 ((c^2) (r^2) (S1-S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^4) (S1-S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4))+(b^2) (S1+S2) ((d^2) (r^2) (S2-S3) (S3-S4)+(c^4) (S2-S3) (S3+S4)+(c^2) (S2+S3) ((d^2) (S3-S4)+(r^2) (S3+S4)))) Cos[θ])/(r ((b^2) (S0-S1) ((c^2) (S1+S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^2) (S1-S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4)))+(a^2) (S0+S1) ((c^2) (S1-S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^2) (S1+S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4))))))

r=a

V1out=-((2 (a^2) E0 S0 ((c^2) (r^2) (S1-S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^4) (S1-S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4))+(b^2) (S1+S2) ((d^2) (r^2) (S2-S3) (S3-S4)+(c^4) (S2-S3) (S3+S4)+(c^2) (S2+S3) ((d^2) (S3-S4)+(r^2) (S3+S4)))) Cos[θ])/(r ((b^2) (S0-S1) ((c^2) (S1+S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^2) (S1-S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4)))+(a^2) (S0+S1) ((c^2) (S1-S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^2) (S1+S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4))))))

r=b

V1in=-((2 (a^2) E0 S0 ((c^2) (r^2) (S1-S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^4) (S1-S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4))+(b^2) (S1+S2) ((d^2) (r^2) (S2-S3) (S3-S4)+(c^4) (S2-S3) (S3+S4)+(c^2) (S2+S3) ((d^2) (S3-S4)+(r^2) (S3+S4)))) Cos[θ])/(r ((b^2) (S0-S1) ((c^2) (S1+S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^2) (S1-S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4)))+(a^2) (S0+S1) ((c^2) (S1-S2) ((d^2) (S2+S3) (S3-S4)+(c^2) (S2-S3) (S3+S4))+(b^2) (S1+S2) ((d^2) (S2-S3) (S3-S4)+(c^2) (S2+S3) (S3+S4))))))

/ Step 2: Voltage drop across the myelin sheath is defined as the voltage difference between the two sides. */

Vmyelin=V1in-V1out

FullSimplify[%6]

/ * Step 3: Validation: if myelin thickness is zero, there shall be no voltage drop across it. */

a=b

Vmyelin