Exhibit 10(d)(xiii)

ASSET PURCHASE AGREEMENT
Dated as of December 11, 2004Between
ACCURAY INCORPORATED
and
AMERICAN SCIENCE AND ENGINEERING, INC.

---



TABLE OF CONTENTS

|1. Definitions                                  |                                             | 2 
|----------------------------------------------- | ------------------------------------------- | --
|2. Acquisition of Division Assets by Buyer      |                                             | 6 
|                                                | 2.1. Purchase and Sale of Assets            |   
|                                                | 2.2. Excluded Assets                        |   
|                                                | 2.3. Assumption of Liabilities              |   
|                                                | 2.4. Liabilities Not Assumed                |   
|                                                | 2.5. Purchase Price                         |   
|                                                | 2.6. Purchase Price Adjustment              |   
|                                                | 2.7. Purchase Price Allocation              |   
|                                                | 2.8. The Closing                            |   
|                                                | 2.9. Deliveries at the Closing              |   
|3. Representations and Warranties of the Seller |                                             | 8 
|                                                | 3.1. Organization of the Seller             |   
|                                                | 3.2. Authorization of Transaction           |   
|                                                | 3.3. Noncontravention                       |   
|                                                | 3.4. Consents and Approvals                 |   
|                                                | 3.5. Brokers' Fees                          |   
|                                                | 3.6. Title to AcquiredAssets                |   
|                                                | 3.7. Legal and Other Compliance             |   
|                                                | 3.8. Employment and Employment Taxes        |   
|                                                | 3.9. Intellectual Property                  |   
|                                                | 3.10. Contracts                             |   
|                                                | 3.11. Litigation                            |   
|                                                | 3.12. Environmental Laws and Regulations    |   
|                                                | 3.13. Permits                               |   
|                                                | 3.14. Inventories                           |   
|                                                | 3.15. Full Disclosure                       |   
|4. Representations and Warranties of the Buyer  |                                             | 14
|                                                | 4.1. Organization of the Buyer              |   
|                                                | 4.2. Authority for Agreement                |   
|                                                | 4.3. Noncontravention                       |   
|                                                | 4.4. Brokers' Fees                          |   
|5. Covenants                                    |                                             | 15
|                                                | 5.1. General                                |   
|                                                | 5.2. Notices and Consents                   |   
|                                                | 5.3. Treatment of Division Assets           |   
|                                                | 5.4. Preservation of Division Assets        |   
|                                                | 5.5. Notice of Developments                 |   
|6. Additional Covenant                          |                                             | 15
|                                                | 6.1. Future Assurances                      |   
|                                                | 6.2. Employees                              |   
|                                                | 6.3. Product Warranty Performance           |   
|                                                | 6.4. Conduct of Business                    |   
|                                                | 6.5. Books and Records                      |   
|7. Confidentiality and Non-Solicitation         |                                             | 18
|                                                | 7.1. Confidentiality                        |   
|                                                | 7.2. Non-Soliciation and Non-Hire           |   
|8. Conditions to Obligations to Close           |                                             | 19
|                                                | 8.1. Conditions to Obligations of the Buyer |   
|                                                |                                             |   

i

---



|                   | 8.2. Conditions to Obligations of the Seller   |    | 20
|------------------ | ---------------------------------------------- | -- | --
|9. Indemnification |                                                | 21
|                   | 9.1. Indemnity by Seller                       |    | 21
|                   | 9.2. Indemnity by Buyer                        |    | 21
|                   | 9.3. Matters Involving Third Parties           |    | 21
|10. Termination    |                                                | 22
|                   | 10.1. Termination of Agreement                 |    | 22
|                   | 10.2. Effect of Termination                    |    | 22
|11. Miscellaneous  |                                                | 23
|                   | 11.1. Press Releases and Public Announcements  |    | 23
|                   | 11.2. No Third Party Beneficiaries             |    | 23
|                   | 11.3. Entire Agreement                         |    | 23
|                   | 11.4. Succession and Assignment                |    | 23
|                   | 11.5. Counterparts                             |    | 23
|                   | 11.6. Headings                                 |    | 23
|                   | 11.7. Notices                                  |    | 24
|                   | 11.8. Governing Law                            |    | 24
|                   | 11.9. Amendments and Waivers                   |    | 25
|                   | 11.10. Severability                            |    | 25
|                   | 11.11. Expenses                                |    | 25
|                   | 11.12. Construction                            |    | 25
|                   | 11.13. Incorporation of Exhibits and Schedules |    | 25
|                   | 11.14. Specific Performance                    |    | 25
|                   | 11.15. Waiver of Jury Trial                    |    | 25

|Exhibits   |  |                                          
|---------- |  | -----------------------------------------
|Exhibit A: |  | License Agreement                        
|Exhibit B: |  | Supply Agreement                         
|Exhibit C: |  | Buyer's Promissory Note                  
|Exhibit D: |  | Bill of Sale and Instrument of Assumption
|Exhibit E: |  | Assignment and Assumption of Lease       

|Schedules*          |  |                                              
|------------------- |  | ---------------------------------------------
|Schedule 2.1(a):    |  | Tangible Assets to be Sold (with valuations) 
|Schedule 2.1(c)(3): |  | Purchase Commitments                         
|Schedule 2.2(g):    |  | Excluded Assets                              
|Schedule 2.3:       |  | Liabilities to be Assumed by Buyer           
|Schedule 3.3:       |  | Noncontravention                             
|Schedule 3.4:       |  | Consents and Approvals                       
|Schedule 3.6:       |  | Leased or Licensed Acquired Assets           
|Schedule 3.9:       |  | Intellectual Property                        
|Schedule 3.9(r):    |  | Source Code in Escrow                        
|Schedule 3.10:      |  | Contracts                                    
|Schedule 3.12:      |  | Environmental                                
|Schedule 3.13:      |  | Permits                                      
|Schedule 6.2(a):    |  | Employees to be Employed by Buyer            
|Schedule 6..2(b):   |  | Employees to be Retained/Terminated by Seller
|Schedule 6.2(c):    |  | Transition Employees                         
|Schedule 8.1(l)(1)  |  | Specific Employees Required to Transition    
|Schedule 8.1(l)(2A) |  | Specific Employees Required to Transition    
|Schedule 8.1(l)(2B) |  | Specific Employees Required to Transition    

ii

---



ASSET PURCHASE AGREEMENT

This
Asset Purchase Agreement (the "Agreement") is entered into on December 11, 2004 (the "Effective Date"), by and between Accuray Incorporated, a California corporation (the
"Buyer"), and American Science and Engineering, Inc., a Massachusetts corporation (the "Seller"). Buyer and Seller are collectively referred to herein as the "Parties."

This
Agreement contemplates a transaction in which Buyer will purchase certain of the assets (and assume certain of the liabilities) of the Seller in consideration of the Purchase Price
(subject to certain purchase price adjustments described in §2.6 below). The assets to be purchased by Buyer all relate to the High Energy Systems ("HES") division of the Seller (the
"Division Assets") located at 1383 Shorebird Way in Mountain View, California (the "HES Facility").

Now,
therefore, in consideration of the premises and the mutual promises herein made, and in consideration of the representations, warranties, and covenants herein contained, the Parties
agree as follows.

1.Definitions.

"Acquired
Assets" has the meaning set forth in §2.1.

"Acquired
Intellectual Property" means all Intellectual Property included in the Acquired Assets.

"Action"
means any claim, action, cause of action, suit, inquiry, proceeding or investigation by or before any Governmental Authority.

"Affiliate"
means, with respect to any specified Person at any time, any Person that directly or indirectly through one or more intermediaries, controls, or is controlled by, or is under
common control with such Person (where, for purposes of this definition, "control" (including the terms "controlled by" and
"under common control with") means the possession, directly or indirectly, of the power to direct or cause the direction of the management policies of a person, whether through the ownership of stock,
as an officer, director, trustee or executor, by contract or otherwise).

"Agreement"
has the meaning set forth in the preamble.

"Assumed
Liabilities" has the meaning set forth in §2.3.

"Bill
of Sale" has the meaning set forth in §2.8.

"Business
Day" means any day on which banking institutions in New York, New York are customarily open for the purpose of transacting business.

"Buyer"
has the meaning set forth in the preamble.

"Cash"
means cash and cash equivalents (including marketable securities and short term investments).

"Closing"
has the meaning set forth in §2.7.

"Closing
Date" has the meaning set forth in §2.7.

"Code"
means the federal Internal Revenue Code of 1986 or any successor statute, and the rules and regulations thereunder, and in the case of any referenced section of any such statute,
rule or regulation, any successor section thereto, collectively and as from time to time amended and in effect.

"Confidential
Information" means any and all information concerning the Division Assets other than that information which is already generally or readily obtainable by the public or is
publicly known or becomes publicly known through no fault of Buyer.

2

---



"Contractual
Obligation" means, with respect to any Person, any contract, agreement, deed, mortgage, lease, license, commitment, undertaking, arrangement or understanding, written or
oral, or other document or instrument, including without limitation any document or instrument evidencing or otherwise relating to any Debt but excluding the charter and by-laws of such
Person, to which or by which such Person is a party or otherwise subject or bound or to which or by which any property or right of such Person is subject or bound.

"Division
Assets" has the meaning set forth in the preamble.

"Division
Documentation" means, collectively, all programmers' notes or logs, source code annotations, user guides, manuals, instructions, software architecture designs, layouts, any
know-how, and any other designs, plans, drawings, technical documentation, contracts or materials that are related exclusively or principally in any manner to any Division Assets, whether
in tangible or intangible form.

"Enforceable"
means, with respect to any Contractual Obligation stated to be Enforceable by or against any Person, that such Contractual Obligation is a legal, valid and binding
obligation enforceable by or against such Person in accordance with its terms, except to the extent that enforcement of the rights and remedies created thereby is subject to bankruptcy, insolvency,
reorganization, moratorium and other similar laws of general application affecting the rights and remedies of creditors and to general principles of equity (regardless of whether enforceability is
considered in a proceeding in equity or at law).

"Environmental
Laws" has the meaning set forth in §3.10.

"Excluded
Assets" has the meaning set forth in §2.2.

"GAAP"
means United States generally accepted accounting principles as in effect from time to time, and consistently applied.

"Governmental
Authority" means any United States federal, state or local or any foreign government, governmental authority, regulatory or administrative agency, governmental commission,
court or tribunal (or any department, bureau or division thereof) or any arbitration or mediation body.

"Hazardous
Substances" has the meaning set forth in §3.10.

"Indemnified
Party" has the meaning set forth in §9.3(a).

"Indemnifying
Party" has the meaning set forth in §9.3(a).

"Instrument
of Assumption" has the meaning set forth in §2.8.

"Intellectual
Property" means any and all worldwide industrial and intellectual property rights and all rights associated therewith relating to the business of the HES division,
including any and all such rights associated with (i) patents and applications therefor and all reissues, divisions, renewals, extensions, provisionals, continuations and
continuations-in-part thereof, all inventions (whether patentable or not), invention disclosures, improvements, trade secrets, proprietary information, know how, technology,
technical data, proprietary processes and formulae, algorithms, specifications, customer lists and supplier lists, all industrial designs and any registrations and applications therefore,
(ii) all copyrights, copyright registrations and applications therefor, and all other rights corresponding thereto, all mask works, all computer software, including all source code, object
code, firmware, development tools, files, records and data, all schematics, simulation tools and reports, hardware development tools, and all rights in prototypes and other devices, all databases and
data collections and all rights therein, all moral and economic rights of authors and inventors, however denominated, (iii) all Trademarks, (iv) all proprietary information,
(v) any Contractual Obligations granting rights related to the foregoing used in the production of or existing in the Products, and (vi) any similar or equivalent rights to any of the
foregoing, and all tangible embodiments of the foregoing.

3

---



"Inventory"
or "Inventories" means all finished goods inventory of Products for sale to Buyer or Intraop, all work in process, raw materials, and all other materials and supplies held
for use or consumption by Seller or Buyer in the production of such Products.

"Knowledge"
of a particular fact, circumstance, event or other matter will be deemed if (a) an individual is actually aware of such fact or other matter, or (b) a
reasonably prudent individual in such individual's position could reasonably be expected to discover or otherwise become aware of such fact or other matter in the course of conducting his or her
duties (including e-mails sent to or by such individual). Seller will be deemed to have "knowledge" of a particular fact or other matter if any of the following employees has "knowledge"
(as defined above) of such fact or other matter: Andrey Mishin, Ken Galaznik, Paul Grazewski, Jim Miller and David Skowbo.

"Leases"
has the meaning set forth in §2.1(b).

"Legal
Requirement" means any federal, state, local or foreign law, statute, standard, ordinance, code, order, rule, regulation, resolution or promulgation, or any order, judgment or
decree of any Governmental Authority, or any license, franchise, permit or similar right granted under any of the foregoing, or any similar provision having the force and effect of law.

"Letter
of Credit" means a commercial or standby letter of credit issued by a bank or other financial institution reasonably satisfactory to Seller.

"Liability"
means any debt, liability or obligation (whether known or unknown, whether asserted or unasserted, whether absolute or contingent, whether accrued or unaccrued, whether
liquidated or unliquidated, whether incurred or consequential and whether due or to become due), fine or penalty, whether accrued or fixed, absolute or contingent, matured or unmatured, determined or
determinable, known or unknown, including without limitation those arising under any law, action or governmental order, liabilities for Taxes and those arising under any contract, agreement,
commitment or undertaking of any kind whatsoever (whether written or oral, express or implied).

"License
Agreement" shall mean the License Agreement entered into by and between Buyer and Seller on the Closing Date in substantially the form attached hereto as Exhibit A.

"Lien"
means any mortgage, pledge, lien, security interest, charge, adverse or prior claim, encumbrance, restriction on transfer, conditional sale or other title retention device or
arrangement (including without limitation a capital lease), transfer for the purpose of subjection to the payment of any Debt or other obligation, or restriction on the creation of any of the
foregoing, whether relating to any property or right or the income or profits therefrom; provided, however, that the term "Lien" shall not include (i) statutory liens for Taxes to the extent
that the payment thereof is not in arrears or otherwise due, (ii) encumbrances in the nature of zoning restrictions, easements, rights or restrictions of record on the use of real property if
the same do not impair its use of the Division Assets as currently conducted, (iii) statutory or common law liens to secure landlords, lessors or renters under leases or rental agreements
confined to the premises rented to the extent that no payment or performance under any such lease or rental agreement is in arrears or is otherwise due, (iv) deposits or pledges made in
connection with, or to secure payment of, worker's compensation, unemployment insurance, old age pension programs mandated under applicable Legal Requirements or other social security and
(v) statutory or common law liens in favor of carriers, warehousemen, mechanics and materialmen, statutory or common law liens to secure claims for labor, materials or supplies and other like
liens, which secure obligations to the extent that payment thereof is not in arrears or otherwise due.

"Losses"
has the meaning set forth in §9.1.

"Material
Adverse Change" means any change reasonably likely to have a Material Adverse Effect.

4

---



"Material
Adverse Effect" means any change, event, violation, inaccuracy, circumstance or effect in or on the Acquired Assets that, when considered either singly or in the aggregate
would result in a material adverse effect on the condition (financial or otherwise), properties, assets (including intangible assets, business, operations, or results of operations of the Division
Assets.

"Note"
has the meaning set forth in §2.5.

"Ordinary
Course of Business" means the ordinary course of business consistent with past custom and practice (including with respect to quantity and frequency).

"Party"
and "Parties" have the meanings set forth in the preamble.

"Permits"
has the meaning set forth in §3.11.

"Person"
means an individual, a partnership, a corporation, an association, a joint stock company, a limited liability company, a trust, a joint venture, an unincorporated organization,
or a Governmental Authority.

"Products"
means all (i) current products and services for sale to Buyer and Intraop that are produced, developed, marketed, licensed, sold, distributed, performed or commercially
exploited by or on behalf of the Seller, and (ii) all products or services currently under development by the Seller, that relate exclusively to the Division Assets.

"Purchase
Price" means (i) the assumption of the Assumed Liabilities, (ii) the cash payable pursuant to §2.5 and (iii) the Buyer's Note.

"Retained
Liabilities" has the meaning set forth in §2.4.

"Seller"
has the meaning set forth in the preamble.

"Seller
Registered Intellectual Property" means all United States, international and foreign: (i) patents and patent applications (including provisional applications);
(ii) registered trademarks, applications to register trademarks, including intent-to-use applications, or other registrations or applications related to trademarks;
(iii) registered copyrights and applications for copyright registration; and (v) any other Intellectual Property that is the subject of an application, certificate, filing, registration
or other document issued, filed with, or recorded by any governmental authority owned by, registered or filed in the name of the Seller.

"Supply
Agreement" shall mean the Supply Agreement entered into by and between the Buyer and the Seller on the Closing Date in substantially the form attached hereto as Exhibit B.

"Tax"
or "Taxes" means any federal, state, local, or foreign income, gross receipts, license, payroll, employment, excise, severance, stamp, occupation, premium, windfall profits,
environmental (including taxes under Code §59A), customs duties, capital stock, franchise, profits, withholding, social security (or similar, including FICA), unemployment, disability,
real property, personal property, inventory, sales, use, ad valorem, transfer, registration, value added, alternative or add-on minimum, estimated, or other tax of any kind whatsoever,
including any interest, penalty, or addition thereto, whether disputed or not.

"Tax
Return" means any return, declaration, report, claim for refund, or information return or statement relating to Taxes, including any schedule or attachment thereto, and including
any amendment thereof.

"Technology"
means all inventions, copyrightable works, discoveries, innovations, know-how, information (including ideas, research and development, know-how,
formulas, compositions, processes and techniques, technical data, designs, drawings, specifications, customer and supplier lists, pricing and cost information, business and marketing plans and
proposals, documentation, and manuals), and all

5

---



other
forms of technology, including improvements, modifications, derivatives or changes, whether or not protectible or protected by patent, copyright, mask work right, trade secret law or otherwise.

"Third
Party Claim" has the meaning set forth in §9.3(a).

"Third
Party Intellectual Property Rights" means any Intellectual Property owned by a third party.

"Trademarks"
means any and all trademarks, trade names, service marks, trade dress, common law trademarks and logos, all trademark and service mark registrations and applications
therefore, together with all translations, adaptations, derivations, and combinations thereof and including all goodwill associated therewith.

2.Acquisition of Division Assets by Buyer.



6

---





7

---





3.Representations and Warranties of the Seller.

The
Seller represents and warrants to the Buyer that the statements contained in this §3 are true and correct as of the date of this Agreement and, unless a date is specified
in such representation and warranty, will be true and correct as of the Closing Date (as though made then and as though the Closing Date were substituted for the date of this Agreement throughout this
§3), except as set forth in the disclosure schedules delivered by Seller to Buyer separately from this Agreement and dated as of the date hereof (the "Seller's Disclosure Letter"). The
Seller's Disclosure Letter shall be arranged in separate parts corresponding to the numbered and lettered sections contained in this Agreement.

8

---





9

---





10

---





11

---





12

---





13

---





4.Representations and Warranties of the Buyer.

The
Buyer represents and warrants to the Seller that the statements contained in this §4 are correct and complete as of the date of this Agreement and, unless a date is
specified in such representation and warranty, will be correct and complete as of the Closing Date (as though made then and as though the Closing Date were substituted for the date of this Agreement
throughout this §4).



14

---



5.Covenants.

The
Parties agree as follows:



6.Additional Covenants



15

---





16

---





17

---





7.Confidentiality and Non-Solicitation



18

---





8.Conditions to Obligations to Close.



19

---





The
Buyer may waive any condition specified in this §8.1 in a writing signed by Buyer.



20

---





The
Seller may waive any condition specified in this § 8.2 in a writing signed by Seller.

9.Indemnification.



21

---





10.Termination.



22

---





11.Miscellaneous.



23

---





If
to Seller:



Copy
to:



If
to Buyer:



Copy
to:



Either
Party may send any notice, request, demand, claim, or other communication hereunder to the intended recipient at the address set forth above using any other means (including
personal delivery, expedited courier, messenger service, telecopy, telex, ordinary mail, or electronic mail), but no such notice, request, demand, claim, or other communication shall be deemed to have
been duly given unless and until it actually is received by the intended recipient. Either Party may change the address to which notices, requests, demands, claims, and other communications hereunder
are to be delivered by giving the other Party notice in the manner herein set forth.



24

---





[The
remainder of this page is intentionally left blank.]

25

---



Asset Purchase Agreement

IN WITNESS WHEREOF, the Parties hereto have executed this Agreement on the date first above written.

| |  | ACCURAY INCORPORATED                  
| |  | --------------------------------------
| |  | By:                                   
| |  | AMERICAN SCIENCE AND ENGINEERING, INC.
| |  | By:                                   

26

---



QuickLinks