Hi Samuel,
Are you looking for the Swept Path line as required on the ground for light rail sytems, for road markings etc or for full 3d guaging /kinematics??
I think you should create planes along a dynamo polycurve representation (look to dynamo primer, it has a sample workflow that may help Rail | Dynamo).
So with your dynamo geometry / polycurve of the centrerline alignment string (civil3d toolkit etc for that) at whatever stationing you require (the stationing will define the accuracy of the output offset line geometry, so closer the better, say 0.25m).
Then to calculate the offsets just maybe use a lookup table to calculate offsets based on centre and end throws of the vehicle etc, then add the offsets for applied cant based on radius.
You will have to consider lengths of your vehcles and how they dynamicaly move along the track how the max and min throw is a function of the dynamic vehicle geometry calculated at each static track point and calculate the relationships to your lookup tables, to find worst case largest offets at each particular static point.
Then you can just “join the dots” with a polycurve and then create a C3D featureline or Polycurve from this.
For full 3d you would need to have a Profile of your guage, you would place your guage along your algnment at the planes you created, then you would need to use the similar methodology with lookup tables baed on design standards to rotate the guage appropriatley at each plane.
You could then create a surface from all the rotated guages, and do further analysis of this against whatever structures you require.
For track spacings you would need to calculate the above either in 2d or3d and then offset one or both tracks (dynamo curve) from each other and create new alignments and check results.
How you do this is dependant on each situation, each static cross section of the tracks you are analising and associated structures and their locations, its complicated , can be very complicated!! Also depends on alot of additional factors for min distances between vehicles based on your design standards etc
Different Railway companies handle this differently , in the world, also meter guage has its unique requirements, (worked on a rail design for Thailand back in the day, it was meter guage).
Not sure if you have done any speed curves analysis its kind of same principle to get the relationships of the vehicle as it moves along your alignment geometry and how you use lookup tables or excel to make decisions for what offsets should be based on your local railway design standards (i.e swiss). Also the lead in to curves, some design standards handle this differently, you may need to have multiple look up tables that reference each other, probably best to do in excel, so it can be checked by others for QA purposes etc, usually railway companies insist on having guaging designs checked using vefified software such as ‘clearroute’ in UK, so using these methods in self developed scripts is good for feasibility Or initial design stages but I would be careful about issuiung construction designs based on this unless you can verify the accuaracy against measuered survey data, and have this fully agreed with all stakeholders in the project. Believe me you dont want the first train in the morning hitting a bracket because they build it based on your dynamo checked design, yes it can happen, so be vigilant.
Good luck.
Regards,
cjm