# SMILES to 3D Coordinates (XYZ) with Force-Field Minimisation > Approximate 3-D structure from SMILES: XYZ and MOL with bond lengths, angles and energy. Turn a SMILES string or a 2-D MOL file into approximate 3-D coordinates: hydrogens are added, a start geometry is built from the 2-D layout and relaxed with a small UFF-style force field by conjugate gradients or steepest descent. You get XYZ and MOL files, the force-field energy by term, bond-length statistics, a ball-and-stick picture and any distances, angles or dihedrals you ask for. Approximate geometry, not quantum chemistry. Part of the Proofline math notebook and its Molecule Lab. Part of usefulweb.app (https://usefulweb.app/). Part of [Proofline](https://proofline.usefulweb.app/) (ownerApp: proofline). Results are deterministic calculations from the inputs and the listed assumptions; the API returns exactly what the web page shows. ## Use it - Human interface: https://prooflinemoleculegeometry.usefulweb.app/ (interactive tool at https://prooflinemoleculegeometry.usefulweb.app/tool) - JSON API: POST https://prooflinemoleculegeometry.usefulweb.app/api/v1/calculate with a JSON object of inputs (schema: https://prooflinemoleculegeometry.usefulweb.app/api/v1/tool) - OpenAPI: https://prooflinemoleculegeometry.usefulweb.app/openapi.json - MCP (Streamable HTTP): https://prooflinemoleculegeometry.usefulweb.app/mcp - tool `proofline_molecule_geometry` ## Inputs - structure (textarea, required): Structure - A SMILES string (CCO, c1ccccc1, [NH4+]), a MOL/SDF V2000 block or XYZ coordinates. SMILES subset: organic atoms B C N O P S F Cl Br I and aromatic b c n o p s, bracket atoms with isotope, hydrogens and charge, bonds - = # :, branches, ring numbers and %nn, dots between parts. Stereo marks are read but not used. At most 300 atoms including hydrogens. - format (select): Format - method (select): Minimiser - maxIterations (integer): Maximum iterations - Per start; minimisation stops earlier when the largest gradient is below 0.001 kcal/mol/Å. - starts (integer): Starting structures - Different seeded start geometries; the one with the lowest energy is kept. - measure (text): Measure (optional) - Atom numbers of the result (hydrogens come after the heavy atoms): two for a distance, three for an angle, four for a dihedral, separated by commas. ## Method - Hydrogens are added, the 2-D layout (stress majorisation, then bond and angle refinement) gives x and y, and a seeded jitter gives z; hydrogens start away from their neighbours. Each start is first relaxed with soft repulsion only, then with the full force field. - Force field (UFF-inspired subset): bond stretch k(r − r₀)² with r₀ from Pyykkö’s single, double and triple covalent radii (aromatic in between); angle bend in cos θ with natural angles 109.47°/120°/180° from the hybridisation (UFF values for O, N, S, P in sp³, 60° and 88° in three- and four-membered rings); UFF-form torsions (3-fold sp³–sp³, 2-fold across double and aromatic bonds, 6-fold sp²–sp³); a planarity term for sp² centres; Lennard-Jones 12-6 with UFF van der Waals parameters for atoms three or more bonds apart (1-4 pairs halved). - Minimisation: Polak–Ribière+ conjugate gradients with a backtracking line search and restarts, or steepest descent; it stops when the largest gradient component is below 0.001 kcal/mol/Å. The structure is centred and turned so its longest extent lies along x. - Approximate geometry, not quantum chemistry: no charges, no solvent, no stereo; expect bond lengths within about ±0.03 Å and angles within a few degrees of experiment, and a local energy minimum (conformers are not searched). ## Limits - Force-field geometries are approximate and the energy is only meaningful to compare conformations of the same molecule. Nothing here is advice on handling chemicals safely.