<?xml version="1.0" encoding="UTF-8"?>
<simulation xmds-version="2">
  <name>halt_non_finite</name>
  <author>Gabriel McManus</author>
  <description>
    An ODE with NaN derivatives.
    Used to test the halt_non_finite feature.
  </description>
  
  <features>
    <benchmark />
    <halt_non_finite />
    <globals>
      <![CDATA[
      const real x0 = 1.0;
      const real t0 = 1.0;
      ]]>
    </globals>
  </features>
  
  <geometry>
    <propagation_dimension> t </propagation_dimension>
  </geometry>
  
  <vector name="main" type="real">
    <components> x </components>
    <initialisation>
      <![CDATA[
      x = x0;
      ]]>
    </initialisation>
  </vector>
  
  <sequence>
    <integrate algorithm="ARK45" interval="2" steps="10000" tolerance="1e-5">
      <samples>200</samples>
      <operators>
        <integration_vectors>main</integration_vectors>
        <![CDATA[
          dx_dt = sqrt(t0 - t);
        ]]>
      </operators>
    </integrate>
  </sequence>
  
  <output>
      <sampling_group initial_sample="yes">
        <moments>xOut</moments>
        <dependencies>main</dependencies>
        <![CDATA[
          xOut = x;
        ]]>
      </sampling_group>
  </output>
  
</simulation>
